@gitopia/gitopiajs 0.0.3 → 0.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +3 -3
- package/dist/LICENSE +0 -21
- package/dist/amino/amino.d.ts +0 -1
- package/dist/amino/amino.js +0 -2
- package/dist/amino/bundle.d.ts +0 -1
- package/dist/amino/bundle.js +0 -41
- package/dist/binary.d.ts +0 -130
- package/dist/binary.js +0 -371
- package/dist/cosmos/bank/v1beta1/bank.d.ts +0 -407
- package/dist/cosmos/bank/v1beta1/bank.js +0 -664
- package/dist/cosmos/bank/v1beta1/query.d.ts +0 -1062
- package/dist/cosmos/bank/v1beta1/query.js +0 -1759
- package/dist/cosmos/bank/v1beta1/query.lcd.d.ts +0 -19
- package/dist/cosmos/bank/v1beta1/query.lcd.js +0 -173
- package/dist/cosmos/bank/v1beta1/query.rpc.Query.d.ts +0 -106
- package/dist/cosmos/bank/v1beta1/query.rpc.Query.js +0 -123
- package/dist/cosmos/base/query/v1beta1/pagination.d.ts +0 -190
- package/dist/cosmos/base/query/v1beta1/pagination.js +0 -204
- package/dist/cosmos/base/v1beta1/coin.d.ts +0 -193
- package/dist/cosmos/base/v1beta1/coin.js +0 -306
- package/dist/cosmos/bundle.d.ts +0 -2311
- package/dist/cosmos/bundle.js +0 -134
- package/dist/cosmos/client.d.ts +0 -84
- package/dist/cosmos/client.js +0 -65
- package/dist/cosmos/feegrant/v1beta1/feegrant.d.ts +0 -245
- package/dist/cosmos/feegrant/v1beta1/feegrant.js +0 -456
- package/dist/cosmos/feegrant/v1beta1/query.d.ts +0 -258
- package/dist/cosmos/feegrant/v1beta1/query.js +0 -487
- package/dist/cosmos/feegrant/v1beta1/query.lcd.d.ts +0 -11
- package/dist/cosmos/feegrant/v1beta1/query.lcd.js +0 -44
- package/dist/cosmos/feegrant/v1beta1/query.rpc.Query.d.ts +0 -28
- package/dist/cosmos/feegrant/v1beta1/query.rpc.Query.js +0 -47
- package/dist/cosmos/gov/v1beta1/gov.d.ts +0 -571
- package/dist/cosmos/gov/v1beta1/gov.js +0 -1122
- package/dist/cosmos/gov/v1beta1/query.d.ts +0 -636
- package/dist/cosmos/gov/v1beta1/query.js +0 -1264
- package/dist/cosmos/gov/v1beta1/query.lcd.d.ts +0 -16
- package/dist/cosmos/gov/v1beta1/query.lcd.js +0 -87
- package/dist/cosmos/gov/v1beta1/query.rpc.Query.d.ts +0 -44
- package/dist/cosmos/gov/v1beta1/query.rpc.Query.js +0 -92
- package/dist/cosmos/group/v1/query.d.ts +0 -1097
- package/dist/cosmos/group/v1/query.js +0 -2182
- package/dist/cosmos/group/v1/query.lcd.d.ts +0 -22
- package/dist/cosmos/group/v1/query.lcd.js +0 -158
- package/dist/cosmos/group/v1/query.rpc.Query.d.ts +0 -78
- package/dist/cosmos/group/v1/query.rpc.Query.js +0 -148
- package/dist/cosmos/group/v1/tx.amino.d.ts +0 -73
- package/dist/cosmos/group/v1/tx.amino.js +0 -77
- package/dist/cosmos/group/v1/tx.d.ts +0 -1198
- package/dist/cosmos/group/v1/tx.js +0 -2362
- package/dist/cosmos/group/v1/tx.registry.d.ts +0 -180
- package/dist/cosmos/group/v1/tx.registry.js +0 -271
- package/dist/cosmos/group/v1/tx.rpc.msg.d.ts +0 -51
- package/dist/cosmos/group/v1/tx.rpc.msg.js +0 -96
- package/dist/cosmos/group/v1/types.d.ts +0 -873
- package/dist/cosmos/group/v1/types.js +0 -1495
- package/dist/cosmos/msg/v1/msg.d.ts +0 -1
- package/dist/cosmos/msg/v1/msg.js +0 -2
- package/dist/cosmos/query/v1/query.d.ts +0 -1
- package/dist/cosmos/query/v1/query.js +0 -2
- package/dist/cosmos/rpc.query.d.ts +0 -59
- package/dist/cosmos/rpc.query.js +0 -60
- package/dist/cosmos/rpc.tx.d.ts +0 -10
- package/dist/cosmos/rpc.tx.js +0 -44
- package/dist/cosmos/upgrade/v1beta1/upgrade.d.ts +0 -278
- package/dist/cosmos/upgrade/v1beta1/upgrade.js +0 -382
- package/dist/cosmos_proto/bundle.d.ts +0 -32
- package/dist/cosmos_proto/bundle.js +0 -41
- package/dist/cosmos_proto/cosmos.d.ts +0 -171
- package/dist/cosmos_proto/cosmos.js +0 -221
- package/dist/esm/amino/amino.js +0 -1
- package/dist/esm/amino/bundle.js +0 -5
- package/dist/esm/binary.js +0 -366
- package/dist/esm/cosmos/bank/v1beta1/bank.js +0 -661
- package/dist/esm/cosmos/bank/v1beta1/query.js +0 -1756
- package/dist/esm/cosmos/bank/v1beta1/query.lcd.js +0 -169
- package/dist/esm/cosmos/bank/v1beta1/query.rpc.Query.js +0 -118
- package/dist/esm/cosmos/base/query/v1beta1/pagination.js +0 -201
- package/dist/esm/cosmos/base/v1beta1/coin.js +0 -303
- package/dist/esm/cosmos/bundle.js +0 -98
- package/dist/esm/cosmos/client.js +0 -27
- package/dist/esm/cosmos/feegrant/v1beta1/feegrant.js +0 -450
- package/dist/esm/cosmos/feegrant/v1beta1/query.js +0 -484
- package/dist/esm/cosmos/feegrant/v1beta1/query.lcd.js +0 -40
- package/dist/esm/cosmos/feegrant/v1beta1/query.rpc.Query.js +0 -42
- package/dist/esm/cosmos/gov/v1beta1/gov.js +0 -1112
- package/dist/esm/cosmos/gov/v1beta1/query.js +0 -1261
- package/dist/esm/cosmos/gov/v1beta1/query.lcd.js +0 -83
- package/dist/esm/cosmos/gov/v1beta1/query.rpc.Query.js +0 -87
- package/dist/esm/cosmos/group/v1/query.js +0 -2179
- package/dist/esm/cosmos/group/v1/query.lcd.js +0 -154
- package/dist/esm/cosmos/group/v1/query.rpc.Query.js +0 -143
- package/dist/esm/cosmos/group/v1/tx.amino.js +0 -74
- package/dist/esm/cosmos/group/v1/tx.js +0 -2354
- package/dist/esm/cosmos/group/v1/tx.registry.js +0 -267
- package/dist/esm/cosmos/group/v1/tx.rpc.msg.js +0 -92
- package/dist/esm/cosmos/group/v1/types.js +0 -1483
- package/dist/esm/cosmos/msg/v1/msg.js +0 -1
- package/dist/esm/cosmos/query/v1/query.js +0 -1
- package/dist/esm/cosmos/rpc.query.js +0 -23
- package/dist/esm/cosmos/rpc.tx.js +0 -7
- package/dist/esm/cosmos/upgrade/v1beta1/upgrade.js +0 -379
- package/dist/esm/cosmos_proto/bundle.js +0 -5
- package/dist/esm/cosmos_proto/cosmos.js +0 -216
- package/dist/esm/gitopia/bundle.js +0 -95
- package/dist/esm/gitopia/client.js +0 -32
- package/dist/esm/gitopia/custom-lcd-client.js +0 -50
- package/dist/esm/gitopia/gitopia/gitopia/attachment.js +0 -101
- package/dist/esm/gitopia/gitopia/gitopia/bounty.js +0 -255
- package/dist/esm/gitopia/gitopia/gitopia/branch.js +0 -137
- package/dist/esm/gitopia/gitopia/gitopia/comment.js +0 -488
- package/dist/esm/gitopia/gitopia/gitopia/dao.js +0 -451
- package/dist/esm/gitopia/gitopia/gitopia/exercised_amount.js +0 -78
- package/dist/esm/gitopia/gitopia/gitopia/genesis.js +0 -460
- package/dist/esm/gitopia/gitopia/gitopia/issue.js +0 -323
- package/dist/esm/gitopia/gitopia/gitopia/params.js +0 -293
- package/dist/esm/gitopia/gitopia/gitopia/pullRequest.js +0 -565
- package/dist/esm/gitopia/gitopia/gitopia/query.js +0 -7351
- package/dist/esm/gitopia/gitopia/gitopia/query.lcd.js +0 -452
- package/dist/esm/gitopia/gitopia/gitopia/query.rpc.Query.js +0 -453
- package/dist/esm/gitopia/gitopia/gitopia/reaction.js +0 -123
- package/dist/esm/gitopia/gitopia/gitopia/release.js +0 -225
- package/dist/esm/gitopia/gitopia/gitopia/repository.js +0 -1200
- package/dist/esm/gitopia/gitopia/gitopia/tag.js +0 -125
- package/dist/esm/gitopia/gitopia/gitopia/task.js +0 -197
- package/dist/esm/gitopia/gitopia/gitopia/tx.amino.js +0 -464
- package/dist/esm/gitopia/gitopia/gitopia/tx.js +0 -14679
- package/dist/esm/gitopia/gitopia/gitopia/tx.registry.js +0 -1671
- package/dist/esm/gitopia/gitopia/gitopia/tx.rpc.msg.js +0 -560
- package/dist/esm/gitopia/gitopia/gitopia/user.js +0 -340
- package/dist/esm/gitopia/gitopia/gitopia/whois.js +0 -146
- package/dist/esm/gitopia/gitopia/offchain/offchain.js +0 -144
- package/dist/esm/gitopia/gitopia/rewards/genesis.js +0 -82
- package/dist/esm/gitopia/gitopia/rewards/params.js +0 -81
- package/dist/esm/gitopia/gitopia/rewards/pool.js +0 -191
- package/dist/esm/gitopia/gitopia/rewards/query.js +0 -654
- package/dist/esm/gitopia/gitopia/rewards/query.lcd.js +0 -40
- package/dist/esm/gitopia/gitopia/rewards/query.rpc.Query.js +0 -53
- package/dist/esm/gitopia/gitopia/rewards/rewards.js +0 -191
- package/dist/esm/gitopia/gitopia/rewards/task.js +0 -176
- package/dist/esm/gitopia/gitopia/rewards/tx.amino.js +0 -19
- package/dist/esm/gitopia/gitopia/rewards/tx.js +0 -525
- package/dist/esm/gitopia/gitopia/rewards/tx.registry.js +0 -69
- package/dist/esm/gitopia/gitopia/rewards/tx.rpc.msg.js +0 -26
- package/dist/esm/gitopia/rpc.query.js +0 -29
- package/dist/esm/gitopia/rpc.tx.js +0 -13
- package/dist/esm/gogoproto/bundle.js +0 -5
- package/dist/esm/gogoproto/gogo.js +0 -1
- package/dist/esm/google/api/annotations.js +0 -1
- package/dist/esm/google/api/http.js +0 -329
- package/dist/esm/google/bundle.js +0 -14
- package/dist/esm/google/protobuf/any.js +0 -74
- package/dist/esm/google/protobuf/descriptor.js +0 -4848
- package/dist/esm/google/protobuf/duration.js +0 -71
- package/dist/esm/google/protobuf/timestamp.js +0 -68
- package/dist/esm/helpers.js +0 -129
- package/dist/esm/ibc/applications/transfer/v1/query.js +0 -847
- package/dist/esm/ibc/applications/transfer/v1/query.lcd.js +0 -70
- package/dist/esm/ibc/applications/transfer/v1/query.rpc.Query.js +0 -71
- package/dist/esm/ibc/applications/transfer/v1/transfer.js +0 -164
- package/dist/esm/ibc/applications/transfer/v1/tx.amino.js +0 -9
- package/dist/esm/ibc/applications/transfer/v1/tx.js +0 -226
- package/dist/esm/ibc/applications/transfer/v1/tx.registry.js +0 -33
- package/dist/esm/ibc/applications/transfer/v1/tx.rpc.msg.js +0 -14
- package/dist/esm/ibc/bundle.js +0 -44
- package/dist/esm/ibc/client.js +0 -29
- package/dist/esm/ibc/core/client/v1/client.js +0 -611
- package/dist/esm/ibc/rpc.query.js +0 -30
- package/dist/esm/ibc/rpc.tx.js +0 -14
- package/dist/esm/index.js +0 -19
- package/dist/esm/utf8.js +0 -137
- package/dist/esm/varint.js +0 -408
- package/dist/gitopia/bundle.d.ts +0 -6123
- package/dist/gitopia/bundle.js +0 -131
- package/dist/gitopia/client.d.ts +0 -492
- package/dist/gitopia/client.js +0 -70
- package/dist/gitopia/custom-lcd-client.d.ts +0 -31
- package/dist/gitopia/custom-lcd-client.js +0 -87
- package/dist/gitopia/gitopia/gitopia/attachment.d.ts +0 -39
- package/dist/gitopia/gitopia/gitopia/attachment.js +0 -104
- package/dist/gitopia/gitopia/gitopia/bounty.d.ts +0 -79
- package/dist/gitopia/gitopia/gitopia/bounty.js +0 -262
- package/dist/gitopia/gitopia/gitopia/branch.d.ts +0 -48
- package/dist/gitopia/gitopia/gitopia/branch.js +0 -140
- package/dist/gitopia/gitopia/gitopia/comment.d.ts +0 -125
- package/dist/gitopia/gitopia/gitopia/comment.js +0 -495
- package/dist/gitopia/gitopia/gitopia/dao.d.ts +0 -160
- package/dist/gitopia/gitopia/gitopia/dao.js +0 -454
- package/dist/gitopia/gitopia/gitopia/exercised_amount.d.ts +0 -34
- package/dist/gitopia/gitopia/gitopia/exercised_amount.js +0 -81
- package/dist/gitopia/gitopia/gitopia/genesis.d.ts +0 -143
- package/dist/gitopia/gitopia/gitopia/genesis.js +0 -463
- package/dist/gitopia/gitopia/gitopia/issue.d.ts +0 -88
- package/dist/gitopia/gitopia/gitopia/issue.js +0 -328
- package/dist/gitopia/gitopia/gitopia/params.d.ts +0 -115
- package/dist/gitopia/gitopia/gitopia/params.js +0 -296
- package/dist/gitopia/gitopia/gitopia/pullRequest.d.ts +0 -177
- package/dist/gitopia/gitopia/gitopia/pullRequest.js +0 -570
- package/dist/gitopia/gitopia/gitopia/query.d.ts +0 -3130
- package/dist/gitopia/gitopia/gitopia/query.js +0 -7355
- package/dist/gitopia/gitopia/gitopia/query.lcd.d.ts +0 -54
- package/dist/gitopia/gitopia/gitopia/query.lcd.js +0 -456
- package/dist/gitopia/gitopia/gitopia/query.rpc.Query.d.ts +0 -188
- package/dist/gitopia/gitopia/gitopia/query.rpc.Query.js +0 -458
- package/dist/gitopia/gitopia/gitopia/reaction.d.ts +0 -42
- package/dist/gitopia/gitopia/gitopia/reaction.js +0 -128
- package/dist/gitopia/gitopia/gitopia/release.d.ts +0 -70
- package/dist/gitopia/gitopia/gitopia/release.js +0 -228
- package/dist/gitopia/gitopia/gitopia/repository.d.ts +0 -424
- package/dist/gitopia/gitopia/gitopia/repository.js +0 -1207
- package/dist/gitopia/gitopia/gitopia/tag.d.ts +0 -45
- package/dist/gitopia/gitopia/gitopia/tag.js +0 -128
- package/dist/gitopia/gitopia/gitopia/task.d.ts +0 -64
- package/dist/gitopia/gitopia/gitopia/task.js +0 -204
- package/dist/gitopia/gitopia/gitopia/tx.amino.d.ts +0 -463
- package/dist/gitopia/gitopia/gitopia/tx.amino.js +0 -467
- package/dist/gitopia/gitopia/gitopia/tx.d.ts +0 -6246
- package/dist/gitopia/gitopia/gitopia/tx.js +0 -14687
- package/dist/gitopia/gitopia/gitopia/tx.registry.d.ts +0 -1116
- package/dist/gitopia/gitopia/gitopia/tx.registry.js +0 -1675
- package/dist/gitopia/gitopia/gitopia/tx.rpc.msg.d.ts +0 -200
- package/dist/gitopia/gitopia/gitopia/tx.rpc.msg.js +0 -564
- package/dist/gitopia/gitopia/gitopia/user.d.ts +0 -104
- package/dist/gitopia/gitopia/gitopia/user.js +0 -343
- package/dist/gitopia/gitopia/gitopia/whois.d.ts +0 -51
- package/dist/gitopia/gitopia/gitopia/whois.js +0 -151
- package/dist/gitopia/gitopia/offchain/offchain.d.ts +0 -74
- package/dist/gitopia/gitopia/offchain/offchain.js +0 -147
- package/dist/gitopia/gitopia/rewards/genesis.d.ts +0 -40
- package/dist/gitopia/gitopia/rewards/genesis.js +0 -85
- package/dist/gitopia/gitopia/rewards/params.d.ts +0 -37
- package/dist/gitopia/gitopia/rewards/params.js +0 -84
- package/dist/gitopia/gitopia/rewards/pool.d.ts +0 -59
- package/dist/gitopia/gitopia/rewards/pool.js +0 -196
- package/dist/gitopia/gitopia/rewards/query.d.ts +0 -294
- package/dist/gitopia/gitopia/rewards/query.js +0 -657
- package/dist/gitopia/gitopia/rewards/query.lcd.d.ts +0 -12
- package/dist/gitopia/gitopia/rewards/query.lcd.js +0 -44
- package/dist/gitopia/gitopia/rewards/query.rpc.Query.d.ts +0 -28
- package/dist/gitopia/gitopia/rewards/query.rpc.Query.js +0 -58
- package/dist/gitopia/gitopia/rewards/rewards.d.ts +0 -79
- package/dist/gitopia/gitopia/rewards/rewards.js +0 -194
- package/dist/gitopia/gitopia/rewards/task.d.ts +0 -54
- package/dist/gitopia/gitopia/rewards/task.js +0 -181
- package/dist/gitopia/gitopia/rewards/tx.amino.d.ts +0 -18
- package/dist/gitopia/gitopia/rewards/tx.amino.js +0 -22
- package/dist/gitopia/gitopia/rewards/tx.d.ts +0 -242
- package/dist/gitopia/gitopia/rewards/tx.js +0 -528
- package/dist/gitopia/gitopia/rewards/tx.registry.d.ts +0 -48
- package/dist/gitopia/gitopia/rewards/tx.registry.js +0 -73
- package/dist/gitopia/gitopia/rewards/tx.rpc.msg.d.ts +0 -19
- package/dist/gitopia/gitopia/rewards/tx.rpc.msg.js +0 -30
- package/dist/gitopia/rpc.query.d.ts +0 -117
- package/dist/gitopia/rpc.query.js +0 -66
- package/dist/gitopia/rpc.tx.d.ts +0 -16
- package/dist/gitopia/rpc.tx.js +0 -50
- package/dist/gogoproto/bundle.d.ts +0 -1
- package/dist/gogoproto/bundle.js +0 -41
- package/dist/gogoproto/gogo.d.ts +0 -1
- package/dist/gogoproto/gogo.js +0 -2
- package/dist/google/api/annotations.d.ts +0 -1
- package/dist/google/api/annotations.js +0 -2
- package/dist/google/api/http.d.ts +0 -1049
- package/dist/google/api/http.js +0 -332
- package/dist/google/bundle.d.ts +0 -525
- package/dist/google/bundle.js +0 -50
- package/dist/google/protobuf/any.d.ts +0 -358
- package/dist/google/protobuf/any.js +0 -77
- package/dist/google/protobuf/descriptor.d.ts +0 -3178
- package/dist/google/protobuf/descriptor.js +0 -4886
- package/dist/google/protobuf/duration.d.ts +0 -223
- package/dist/google/protobuf/duration.js +0 -74
- package/dist/google/protobuf/timestamp.d.ts +0 -314
- package/dist/google/protobuf/timestamp.js +0 -71
- package/dist/helpers.d.ts +0 -82
- package/dist/helpers.js +0 -144
- package/dist/ibc/applications/transfer/v1/query.d.ts +0 -479
- package/dist/ibc/applications/transfer/v1/query.js +0 -850
- package/dist/ibc/applications/transfer/v1/query.lcd.d.ts +0 -14
- package/dist/ibc/applications/transfer/v1/query.lcd.js +0 -74
- package/dist/ibc/applications/transfer/v1/query.rpc.Query.d.ts +0 -36
- package/dist/ibc/applications/transfer/v1/query.rpc.Query.js +0 -76
- package/dist/ibc/applications/transfer/v1/transfer.d.ts +0 -123
- package/dist/ibc/applications/transfer/v1/transfer.js +0 -167
- package/dist/ibc/applications/transfer/v1/tx.amino.d.ts +0 -8
- package/dist/ibc/applications/transfer/v1/tx.amino.js +0 -12
- package/dist/ibc/applications/transfer/v1/tx.d.ts +0 -132
- package/dist/ibc/applications/transfer/v1/tx.js +0 -229
- package/dist/ibc/applications/transfer/v1/tx.registry.d.ts +0 -24
- package/dist/ibc/applications/transfer/v1/tx.registry.js +0 -37
- package/dist/ibc/applications/transfer/v1/tx.rpc.msg.d.ts +0 -12
- package/dist/ibc/applications/transfer/v1/tx.rpc.msg.js +0 -18
- package/dist/ibc/bundle.d.ts +0 -450
- package/dist/ibc/bundle.js +0 -80
- package/dist/ibc/client.d.ts +0 -22
- package/dist/ibc/client.js +0 -67
- package/dist/ibc/core/client/v1/client.d.ts +0 -408
- package/dist/ibc/core/client/v1/client.js +0 -614
- package/dist/ibc/rpc.query.d.ts +0 -73
- package/dist/ibc/rpc.query.js +0 -67
- package/dist/ibc/rpc.tx.d.ts +0 -17
- package/dist/ibc/rpc.tx.js +0 -51
- package/dist/index.d.ts +0 -18
- package/dist/index.js +0 -35
- package/dist/package.json +0 -46
- package/dist/utf8.d.ts +0 -27
- package/dist/utf8.js +0 -141
- package/dist/varint.d.ts +0 -105
- package/dist/varint.js +0 -426
|
@@ -1,169 +0,0 @@
|
|
|
1
|
-
//@ts-nocheck
|
|
2
|
-
import { setPaginationParams } from "../../../helpers";
|
|
3
|
-
export class LCDQueryClient {
|
|
4
|
-
req;
|
|
5
|
-
constructor({ requestClient }) {
|
|
6
|
-
this.req = requestClient;
|
|
7
|
-
this.balance = this.balance.bind(this);
|
|
8
|
-
this.allBalances = this.allBalances.bind(this);
|
|
9
|
-
this.spendableBalances = this.spendableBalances.bind(this);
|
|
10
|
-
this.spendableBalanceByDenom = this.spendableBalanceByDenom.bind(this);
|
|
11
|
-
this.totalSupply = this.totalSupply.bind(this);
|
|
12
|
-
this.supplyOf = this.supplyOf.bind(this);
|
|
13
|
-
this.params = this.params.bind(this);
|
|
14
|
-
this.denomMetadata = this.denomMetadata.bind(this);
|
|
15
|
-
this.denomsMetadata = this.denomsMetadata.bind(this);
|
|
16
|
-
this.denomOwners = this.denomOwners.bind(this);
|
|
17
|
-
this.sendEnabled = this.sendEnabled.bind(this);
|
|
18
|
-
}
|
|
19
|
-
/* Balance queries the balance of a single coin for a single account. */
|
|
20
|
-
async balance(params) {
|
|
21
|
-
const options = {
|
|
22
|
-
params: {}
|
|
23
|
-
};
|
|
24
|
-
if (typeof params?.denom !== "undefined") {
|
|
25
|
-
options.params.denom = params.denom;
|
|
26
|
-
}
|
|
27
|
-
const endpoint = `cosmos/bank/v1beta1/balances/${params.address}/by_denom`;
|
|
28
|
-
return await this.req.get(endpoint, options);
|
|
29
|
-
}
|
|
30
|
-
/* AllBalances queries the balance of all coins for a single account.
|
|
31
|
-
|
|
32
|
-
When called from another module, this query might consume a high amount of
|
|
33
|
-
gas if the pagination field is incorrectly set. */
|
|
34
|
-
async allBalances(params) {
|
|
35
|
-
const options = {
|
|
36
|
-
params: {}
|
|
37
|
-
};
|
|
38
|
-
if (typeof params?.pagination !== "undefined") {
|
|
39
|
-
setPaginationParams(options, params.pagination);
|
|
40
|
-
}
|
|
41
|
-
const endpoint = `cosmos/bank/v1beta1/balances/${params.address}`;
|
|
42
|
-
return await this.req.get(endpoint, options);
|
|
43
|
-
}
|
|
44
|
-
/* SpendableBalances queries the spendable balance of all coins for a single
|
|
45
|
-
account.
|
|
46
|
-
|
|
47
|
-
When called from another module, this query might consume a high amount of
|
|
48
|
-
gas if the pagination field is incorrectly set.
|
|
49
|
-
|
|
50
|
-
Since: cosmos-sdk 0.46 */
|
|
51
|
-
async spendableBalances(params) {
|
|
52
|
-
const options = {
|
|
53
|
-
params: {}
|
|
54
|
-
};
|
|
55
|
-
if (typeof params?.pagination !== "undefined") {
|
|
56
|
-
setPaginationParams(options, params.pagination);
|
|
57
|
-
}
|
|
58
|
-
const endpoint = `cosmos/bank/v1beta1/spendable_balances/${params.address}`;
|
|
59
|
-
return await this.req.get(endpoint, options);
|
|
60
|
-
}
|
|
61
|
-
/* SpendableBalanceByDenom queries the spendable balance of a single denom for
|
|
62
|
-
a single account.
|
|
63
|
-
|
|
64
|
-
When called from another module, this query might consume a high amount of
|
|
65
|
-
gas if the pagination field is incorrectly set.
|
|
66
|
-
|
|
67
|
-
Since: cosmos-sdk 0.47 */
|
|
68
|
-
async spendableBalanceByDenom(params) {
|
|
69
|
-
const options = {
|
|
70
|
-
params: {}
|
|
71
|
-
};
|
|
72
|
-
if (typeof params?.denom !== "undefined") {
|
|
73
|
-
options.params.denom = params.denom;
|
|
74
|
-
}
|
|
75
|
-
const endpoint = `cosmos/bank/v1beta1/spendable_balances/${params.address}/by_denom`;
|
|
76
|
-
return await this.req.get(endpoint, options);
|
|
77
|
-
}
|
|
78
|
-
/* TotalSupply queries the total supply of all coins.
|
|
79
|
-
|
|
80
|
-
When called from another module, this query might consume a high amount of
|
|
81
|
-
gas if the pagination field is incorrectly set. */
|
|
82
|
-
async totalSupply(params = {
|
|
83
|
-
pagination: undefined
|
|
84
|
-
}) {
|
|
85
|
-
const options = {
|
|
86
|
-
params: {}
|
|
87
|
-
};
|
|
88
|
-
if (typeof params?.pagination !== "undefined") {
|
|
89
|
-
setPaginationParams(options, params.pagination);
|
|
90
|
-
}
|
|
91
|
-
const endpoint = `cosmos/bank/v1beta1/supply`;
|
|
92
|
-
return await this.req.get(endpoint, options);
|
|
93
|
-
}
|
|
94
|
-
/* SupplyOf queries the supply of a single coin.
|
|
95
|
-
|
|
96
|
-
When called from another module, this query might consume a high amount of
|
|
97
|
-
gas if the pagination field is incorrectly set. */
|
|
98
|
-
async supplyOf(params) {
|
|
99
|
-
const options = {
|
|
100
|
-
params: {}
|
|
101
|
-
};
|
|
102
|
-
if (typeof params?.denom !== "undefined") {
|
|
103
|
-
options.params.denom = params.denom;
|
|
104
|
-
}
|
|
105
|
-
const endpoint = `cosmos/bank/v1beta1/supply/by_denom`;
|
|
106
|
-
return await this.req.get(endpoint, options);
|
|
107
|
-
}
|
|
108
|
-
/* Params queries the parameters of x/bank module. */
|
|
109
|
-
async params(_params = {}) {
|
|
110
|
-
const endpoint = `cosmos/bank/v1beta1/params`;
|
|
111
|
-
return await this.req.get(endpoint);
|
|
112
|
-
}
|
|
113
|
-
/* DenomsMetadata queries the client metadata of a given coin denomination. */
|
|
114
|
-
async denomMetadata(params) {
|
|
115
|
-
const endpoint = `cosmos/bank/v1beta1/denoms_metadata/${params.denom}`;
|
|
116
|
-
return await this.req.get(endpoint);
|
|
117
|
-
}
|
|
118
|
-
/* DenomsMetadata queries the client metadata for all registered coin
|
|
119
|
-
denominations. */
|
|
120
|
-
async denomsMetadata(params = {
|
|
121
|
-
pagination: undefined
|
|
122
|
-
}) {
|
|
123
|
-
const options = {
|
|
124
|
-
params: {}
|
|
125
|
-
};
|
|
126
|
-
if (typeof params?.pagination !== "undefined") {
|
|
127
|
-
setPaginationParams(options, params.pagination);
|
|
128
|
-
}
|
|
129
|
-
const endpoint = `cosmos/bank/v1beta1/denoms_metadata`;
|
|
130
|
-
return await this.req.get(endpoint, options);
|
|
131
|
-
}
|
|
132
|
-
/* DenomOwners queries for all account addresses that own a particular token
|
|
133
|
-
denomination.
|
|
134
|
-
|
|
135
|
-
When called from another module, this query might consume a high amount of
|
|
136
|
-
gas if the pagination field is incorrectly set.
|
|
137
|
-
|
|
138
|
-
Since: cosmos-sdk 0.46 */
|
|
139
|
-
async denomOwners(params) {
|
|
140
|
-
const options = {
|
|
141
|
-
params: {}
|
|
142
|
-
};
|
|
143
|
-
if (typeof params?.pagination !== "undefined") {
|
|
144
|
-
setPaginationParams(options, params.pagination);
|
|
145
|
-
}
|
|
146
|
-
const endpoint = `cosmos/bank/v1beta1/denom_owners/${params.denom}`;
|
|
147
|
-
return await this.req.get(endpoint, options);
|
|
148
|
-
}
|
|
149
|
-
/* SendEnabled queries for SendEnabled entries.
|
|
150
|
-
|
|
151
|
-
This query only returns denominations that have specific SendEnabled settings.
|
|
152
|
-
Any denomination that does not have a specific setting will use the default
|
|
153
|
-
params.default_send_enabled, and will not be returned by this query.
|
|
154
|
-
|
|
155
|
-
Since: cosmos-sdk 0.47 */
|
|
156
|
-
async sendEnabled(params) {
|
|
157
|
-
const options = {
|
|
158
|
-
params: {}
|
|
159
|
-
};
|
|
160
|
-
if (typeof params?.denoms !== "undefined") {
|
|
161
|
-
options.params.denoms = params.denoms;
|
|
162
|
-
}
|
|
163
|
-
if (typeof params?.pagination !== "undefined") {
|
|
164
|
-
setPaginationParams(options, params.pagination);
|
|
165
|
-
}
|
|
166
|
-
const endpoint = `cosmos/bank/v1beta1/send_enabled`;
|
|
167
|
-
return await this.req.get(endpoint, options);
|
|
168
|
-
}
|
|
169
|
-
}
|
|
@@ -1,118 +0,0 @@
|
|
|
1
|
-
import { BinaryReader } from "../../../binary";
|
|
2
|
-
import { createProtobufRpcClient } from "@cosmjs/stargate";
|
|
3
|
-
import { QueryBalanceRequest, QueryBalanceResponse, QueryAllBalancesRequest, QueryAllBalancesResponse, QuerySpendableBalancesRequest, QuerySpendableBalancesResponse, QuerySpendableBalanceByDenomRequest, QuerySpendableBalanceByDenomResponse, QueryTotalSupplyRequest, QueryTotalSupplyResponse, QuerySupplyOfRequest, QuerySupplyOfResponse, QueryParamsRequest, QueryParamsResponse, QueryDenomMetadataRequest, QueryDenomMetadataResponse, QueryDenomsMetadataRequest, QueryDenomsMetadataResponse, QueryDenomOwnersRequest, QueryDenomOwnersResponse, QuerySendEnabledRequest, QuerySendEnabledResponse } from "./query";
|
|
4
|
-
export class QueryClientImpl {
|
|
5
|
-
rpc;
|
|
6
|
-
constructor(rpc) {
|
|
7
|
-
this.rpc = rpc;
|
|
8
|
-
this.balance = this.balance.bind(this);
|
|
9
|
-
this.allBalances = this.allBalances.bind(this);
|
|
10
|
-
this.spendableBalances = this.spendableBalances.bind(this);
|
|
11
|
-
this.spendableBalanceByDenom = this.spendableBalanceByDenom.bind(this);
|
|
12
|
-
this.totalSupply = this.totalSupply.bind(this);
|
|
13
|
-
this.supplyOf = this.supplyOf.bind(this);
|
|
14
|
-
this.params = this.params.bind(this);
|
|
15
|
-
this.denomMetadata = this.denomMetadata.bind(this);
|
|
16
|
-
this.denomsMetadata = this.denomsMetadata.bind(this);
|
|
17
|
-
this.denomOwners = this.denomOwners.bind(this);
|
|
18
|
-
this.sendEnabled = this.sendEnabled.bind(this);
|
|
19
|
-
}
|
|
20
|
-
balance(request) {
|
|
21
|
-
const data = QueryBalanceRequest.encode(request).finish();
|
|
22
|
-
const promise = this.rpc.request("cosmos.bank.v1beta1.Query", "Balance", data);
|
|
23
|
-
return promise.then(data => QueryBalanceResponse.decode(new BinaryReader(data)));
|
|
24
|
-
}
|
|
25
|
-
allBalances(request) {
|
|
26
|
-
const data = QueryAllBalancesRequest.encode(request).finish();
|
|
27
|
-
const promise = this.rpc.request("cosmos.bank.v1beta1.Query", "AllBalances", data);
|
|
28
|
-
return promise.then(data => QueryAllBalancesResponse.decode(new BinaryReader(data)));
|
|
29
|
-
}
|
|
30
|
-
spendableBalances(request) {
|
|
31
|
-
const data = QuerySpendableBalancesRequest.encode(request).finish();
|
|
32
|
-
const promise = this.rpc.request("cosmos.bank.v1beta1.Query", "SpendableBalances", data);
|
|
33
|
-
return promise.then(data => QuerySpendableBalancesResponse.decode(new BinaryReader(data)));
|
|
34
|
-
}
|
|
35
|
-
spendableBalanceByDenom(request) {
|
|
36
|
-
const data = QuerySpendableBalanceByDenomRequest.encode(request).finish();
|
|
37
|
-
const promise = this.rpc.request("cosmos.bank.v1beta1.Query", "SpendableBalanceByDenom", data);
|
|
38
|
-
return promise.then(data => QuerySpendableBalanceByDenomResponse.decode(new BinaryReader(data)));
|
|
39
|
-
}
|
|
40
|
-
totalSupply(request = {
|
|
41
|
-
pagination: undefined
|
|
42
|
-
}) {
|
|
43
|
-
const data = QueryTotalSupplyRequest.encode(request).finish();
|
|
44
|
-
const promise = this.rpc.request("cosmos.bank.v1beta1.Query", "TotalSupply", data);
|
|
45
|
-
return promise.then(data => QueryTotalSupplyResponse.decode(new BinaryReader(data)));
|
|
46
|
-
}
|
|
47
|
-
supplyOf(request) {
|
|
48
|
-
const data = QuerySupplyOfRequest.encode(request).finish();
|
|
49
|
-
const promise = this.rpc.request("cosmos.bank.v1beta1.Query", "SupplyOf", data);
|
|
50
|
-
return promise.then(data => QuerySupplyOfResponse.decode(new BinaryReader(data)));
|
|
51
|
-
}
|
|
52
|
-
params(request = {}) {
|
|
53
|
-
const data = QueryParamsRequest.encode(request).finish();
|
|
54
|
-
const promise = this.rpc.request("cosmos.bank.v1beta1.Query", "Params", data);
|
|
55
|
-
return promise.then(data => QueryParamsResponse.decode(new BinaryReader(data)));
|
|
56
|
-
}
|
|
57
|
-
denomMetadata(request) {
|
|
58
|
-
const data = QueryDenomMetadataRequest.encode(request).finish();
|
|
59
|
-
const promise = this.rpc.request("cosmos.bank.v1beta1.Query", "DenomMetadata", data);
|
|
60
|
-
return promise.then(data => QueryDenomMetadataResponse.decode(new BinaryReader(data)));
|
|
61
|
-
}
|
|
62
|
-
denomsMetadata(request = {
|
|
63
|
-
pagination: undefined
|
|
64
|
-
}) {
|
|
65
|
-
const data = QueryDenomsMetadataRequest.encode(request).finish();
|
|
66
|
-
const promise = this.rpc.request("cosmos.bank.v1beta1.Query", "DenomsMetadata", data);
|
|
67
|
-
return promise.then(data => QueryDenomsMetadataResponse.decode(new BinaryReader(data)));
|
|
68
|
-
}
|
|
69
|
-
denomOwners(request) {
|
|
70
|
-
const data = QueryDenomOwnersRequest.encode(request).finish();
|
|
71
|
-
const promise = this.rpc.request("cosmos.bank.v1beta1.Query", "DenomOwners", data);
|
|
72
|
-
return promise.then(data => QueryDenomOwnersResponse.decode(new BinaryReader(data)));
|
|
73
|
-
}
|
|
74
|
-
sendEnabled(request) {
|
|
75
|
-
const data = QuerySendEnabledRequest.encode(request).finish();
|
|
76
|
-
const promise = this.rpc.request("cosmos.bank.v1beta1.Query", "SendEnabled", data);
|
|
77
|
-
return promise.then(data => QuerySendEnabledResponse.decode(new BinaryReader(data)));
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
export const createRpcQueryExtension = (base) => {
|
|
81
|
-
const rpc = createProtobufRpcClient(base);
|
|
82
|
-
const queryService = new QueryClientImpl(rpc);
|
|
83
|
-
return {
|
|
84
|
-
balance(request) {
|
|
85
|
-
return queryService.balance(request);
|
|
86
|
-
},
|
|
87
|
-
allBalances(request) {
|
|
88
|
-
return queryService.allBalances(request);
|
|
89
|
-
},
|
|
90
|
-
spendableBalances(request) {
|
|
91
|
-
return queryService.spendableBalances(request);
|
|
92
|
-
},
|
|
93
|
-
spendableBalanceByDenom(request) {
|
|
94
|
-
return queryService.spendableBalanceByDenom(request);
|
|
95
|
-
},
|
|
96
|
-
totalSupply(request) {
|
|
97
|
-
return queryService.totalSupply(request);
|
|
98
|
-
},
|
|
99
|
-
supplyOf(request) {
|
|
100
|
-
return queryService.supplyOf(request);
|
|
101
|
-
},
|
|
102
|
-
params(request) {
|
|
103
|
-
return queryService.params(request);
|
|
104
|
-
},
|
|
105
|
-
denomMetadata(request) {
|
|
106
|
-
return queryService.denomMetadata(request);
|
|
107
|
-
},
|
|
108
|
-
denomsMetadata(request) {
|
|
109
|
-
return queryService.denomsMetadata(request);
|
|
110
|
-
},
|
|
111
|
-
denomOwners(request) {
|
|
112
|
-
return queryService.denomOwners(request);
|
|
113
|
-
},
|
|
114
|
-
sendEnabled(request) {
|
|
115
|
-
return queryService.sendEnabled(request);
|
|
116
|
-
}
|
|
117
|
-
};
|
|
118
|
-
};
|
|
@@ -1,201 +0,0 @@
|
|
|
1
|
-
//@ts-nocheck
|
|
2
|
-
import { BinaryReader, BinaryWriter } from "../../../../binary";
|
|
3
|
-
import { bytesFromBase64, base64FromBytes } from "../../../../helpers";
|
|
4
|
-
function createBasePageRequest() {
|
|
5
|
-
return {
|
|
6
|
-
key: new Uint8Array(),
|
|
7
|
-
offset: BigInt(0),
|
|
8
|
-
limit: BigInt(0),
|
|
9
|
-
countTotal: false,
|
|
10
|
-
reverse: false
|
|
11
|
-
};
|
|
12
|
-
}
|
|
13
|
-
export const PageRequest = {
|
|
14
|
-
typeUrl: "/cosmos.base.query.v1beta1.PageRequest",
|
|
15
|
-
encode(message, writer = BinaryWriter.create()) {
|
|
16
|
-
if (message.key.length !== 0) {
|
|
17
|
-
writer.uint32(10).bytes(message.key);
|
|
18
|
-
}
|
|
19
|
-
if (message.offset !== BigInt(0)) {
|
|
20
|
-
writer.uint32(16).uint64(message.offset);
|
|
21
|
-
}
|
|
22
|
-
if (message.limit !== BigInt(0)) {
|
|
23
|
-
writer.uint32(24).uint64(message.limit);
|
|
24
|
-
}
|
|
25
|
-
if (message.countTotal === true) {
|
|
26
|
-
writer.uint32(32).bool(message.countTotal);
|
|
27
|
-
}
|
|
28
|
-
if (message.reverse === true) {
|
|
29
|
-
writer.uint32(40).bool(message.reverse);
|
|
30
|
-
}
|
|
31
|
-
return writer;
|
|
32
|
-
},
|
|
33
|
-
decode(input, length) {
|
|
34
|
-
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
35
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
36
|
-
const message = createBasePageRequest();
|
|
37
|
-
while (reader.pos < end) {
|
|
38
|
-
const tag = reader.uint32();
|
|
39
|
-
switch (tag >>> 3) {
|
|
40
|
-
case 1:
|
|
41
|
-
message.key = reader.bytes();
|
|
42
|
-
break;
|
|
43
|
-
case 2:
|
|
44
|
-
message.offset = reader.uint64();
|
|
45
|
-
break;
|
|
46
|
-
case 3:
|
|
47
|
-
message.limit = reader.uint64();
|
|
48
|
-
break;
|
|
49
|
-
case 4:
|
|
50
|
-
message.countTotal = reader.bool();
|
|
51
|
-
break;
|
|
52
|
-
case 5:
|
|
53
|
-
message.reverse = reader.bool();
|
|
54
|
-
break;
|
|
55
|
-
default:
|
|
56
|
-
reader.skipType(tag & 7);
|
|
57
|
-
break;
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
return message;
|
|
61
|
-
},
|
|
62
|
-
fromPartial(object) {
|
|
63
|
-
const message = createBasePageRequest();
|
|
64
|
-
message.key = object.key ?? new Uint8Array();
|
|
65
|
-
message.offset = object.offset !== undefined && object.offset !== null ? BigInt(object.offset.toString()) : BigInt(0);
|
|
66
|
-
message.limit = object.limit !== undefined && object.limit !== null ? BigInt(object.limit.toString()) : BigInt(0);
|
|
67
|
-
message.countTotal = object.countTotal ?? false;
|
|
68
|
-
message.reverse = object.reverse ?? false;
|
|
69
|
-
return message;
|
|
70
|
-
},
|
|
71
|
-
fromAmino(object) {
|
|
72
|
-
const message = createBasePageRequest();
|
|
73
|
-
if (object.key !== undefined && object.key !== null) {
|
|
74
|
-
message.key = bytesFromBase64(object.key);
|
|
75
|
-
}
|
|
76
|
-
if (object.offset !== undefined && object.offset !== null) {
|
|
77
|
-
message.offset = BigInt(object.offset);
|
|
78
|
-
}
|
|
79
|
-
if (object.limit !== undefined && object.limit !== null) {
|
|
80
|
-
message.limit = BigInt(object.limit);
|
|
81
|
-
}
|
|
82
|
-
if (object.count_total !== undefined && object.count_total !== null) {
|
|
83
|
-
message.countTotal = object.count_total;
|
|
84
|
-
}
|
|
85
|
-
if (object.reverse !== undefined && object.reverse !== null) {
|
|
86
|
-
message.reverse = object.reverse;
|
|
87
|
-
}
|
|
88
|
-
return message;
|
|
89
|
-
},
|
|
90
|
-
toAmino(message) {
|
|
91
|
-
const obj = {};
|
|
92
|
-
obj.key = message.key ? base64FromBytes(message.key) : undefined;
|
|
93
|
-
obj.offset = message.offset !== BigInt(0) ? message.offset?.toString() : undefined;
|
|
94
|
-
obj.limit = message.limit !== BigInt(0) ? message.limit?.toString() : undefined;
|
|
95
|
-
obj.count_total = message.countTotal === false ? undefined : message.countTotal;
|
|
96
|
-
obj.reverse = message.reverse === false ? undefined : message.reverse;
|
|
97
|
-
return obj;
|
|
98
|
-
},
|
|
99
|
-
fromAminoMsg(object) {
|
|
100
|
-
return PageRequest.fromAmino(object.value);
|
|
101
|
-
},
|
|
102
|
-
toAminoMsg(message) {
|
|
103
|
-
return {
|
|
104
|
-
type: "cosmos-sdk/PageRequest",
|
|
105
|
-
value: PageRequest.toAmino(message)
|
|
106
|
-
};
|
|
107
|
-
},
|
|
108
|
-
fromProtoMsg(message) {
|
|
109
|
-
return PageRequest.decode(message.value);
|
|
110
|
-
},
|
|
111
|
-
toProto(message) {
|
|
112
|
-
return PageRequest.encode(message).finish();
|
|
113
|
-
},
|
|
114
|
-
toProtoMsg(message) {
|
|
115
|
-
return {
|
|
116
|
-
typeUrl: "/cosmos.base.query.v1beta1.PageRequest",
|
|
117
|
-
value: PageRequest.encode(message).finish()
|
|
118
|
-
};
|
|
119
|
-
}
|
|
120
|
-
};
|
|
121
|
-
function createBasePageResponse() {
|
|
122
|
-
return {
|
|
123
|
-
nextKey: new Uint8Array(),
|
|
124
|
-
total: BigInt(0)
|
|
125
|
-
};
|
|
126
|
-
}
|
|
127
|
-
export const PageResponse = {
|
|
128
|
-
typeUrl: "/cosmos.base.query.v1beta1.PageResponse",
|
|
129
|
-
encode(message, writer = BinaryWriter.create()) {
|
|
130
|
-
if (message.nextKey.length !== 0) {
|
|
131
|
-
writer.uint32(10).bytes(message.nextKey);
|
|
132
|
-
}
|
|
133
|
-
if (message.total !== BigInt(0)) {
|
|
134
|
-
writer.uint32(16).uint64(message.total);
|
|
135
|
-
}
|
|
136
|
-
return writer;
|
|
137
|
-
},
|
|
138
|
-
decode(input, length) {
|
|
139
|
-
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
140
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
141
|
-
const message = createBasePageResponse();
|
|
142
|
-
while (reader.pos < end) {
|
|
143
|
-
const tag = reader.uint32();
|
|
144
|
-
switch (tag >>> 3) {
|
|
145
|
-
case 1:
|
|
146
|
-
message.nextKey = reader.bytes();
|
|
147
|
-
break;
|
|
148
|
-
case 2:
|
|
149
|
-
message.total = reader.uint64();
|
|
150
|
-
break;
|
|
151
|
-
default:
|
|
152
|
-
reader.skipType(tag & 7);
|
|
153
|
-
break;
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
|
-
return message;
|
|
157
|
-
},
|
|
158
|
-
fromPartial(object) {
|
|
159
|
-
const message = createBasePageResponse();
|
|
160
|
-
message.nextKey = object.nextKey ?? new Uint8Array();
|
|
161
|
-
message.total = object.total !== undefined && object.total !== null ? BigInt(object.total.toString()) : BigInt(0);
|
|
162
|
-
return message;
|
|
163
|
-
},
|
|
164
|
-
fromAmino(object) {
|
|
165
|
-
const message = createBasePageResponse();
|
|
166
|
-
if (object.next_key !== undefined && object.next_key !== null) {
|
|
167
|
-
message.nextKey = bytesFromBase64(object.next_key);
|
|
168
|
-
}
|
|
169
|
-
if (object.total !== undefined && object.total !== null) {
|
|
170
|
-
message.total = BigInt(object.total);
|
|
171
|
-
}
|
|
172
|
-
return message;
|
|
173
|
-
},
|
|
174
|
-
toAmino(message) {
|
|
175
|
-
const obj = {};
|
|
176
|
-
obj.next_key = message.nextKey ? base64FromBytes(message.nextKey) : undefined;
|
|
177
|
-
obj.total = message.total !== BigInt(0) ? message.total?.toString() : undefined;
|
|
178
|
-
return obj;
|
|
179
|
-
},
|
|
180
|
-
fromAminoMsg(object) {
|
|
181
|
-
return PageResponse.fromAmino(object.value);
|
|
182
|
-
},
|
|
183
|
-
toAminoMsg(message) {
|
|
184
|
-
return {
|
|
185
|
-
type: "cosmos-sdk/PageResponse",
|
|
186
|
-
value: PageResponse.toAmino(message)
|
|
187
|
-
};
|
|
188
|
-
},
|
|
189
|
-
fromProtoMsg(message) {
|
|
190
|
-
return PageResponse.decode(message.value);
|
|
191
|
-
},
|
|
192
|
-
toProto(message) {
|
|
193
|
-
return PageResponse.encode(message).finish();
|
|
194
|
-
},
|
|
195
|
-
toProtoMsg(message) {
|
|
196
|
-
return {
|
|
197
|
-
typeUrl: "/cosmos.base.query.v1beta1.PageResponse",
|
|
198
|
-
value: PageResponse.encode(message).finish()
|
|
199
|
-
};
|
|
200
|
-
}
|
|
201
|
-
};
|