@agoric/cosmic-proto 0.4.1-dev-841f246.0 → 0.4.1-dev-203d4d7.0
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/dist/codegen/cosmos/authz/v1beta1/authz.d.ts +6 -5
- package/dist/codegen/cosmos/authz/v1beta1/authz.js +3 -0
- package/dist/codegen/cosmos/authz/v1beta1/authz.js.map +1 -1
- package/dist/codegen/cosmos/bundle.d.ts +1 -1
- package/dist/codegen/ibc/applications/interchain_accounts/controller/v1/controller.d.ts +31 -0
- package/dist/codegen/ibc/applications/interchain_accounts/controller/v1/controller.js +65 -0
- package/dist/codegen/ibc/applications/interchain_accounts/controller/v1/controller.js.map +1 -0
- package/dist/codegen/ibc/applications/interchain_accounts/controller/v1/query.d.ts +95 -0
- package/dist/codegen/ibc/applications/interchain_accounts/controller/v1/query.js +242 -0
- package/dist/codegen/ibc/applications/interchain_accounts/controller/v1/query.js.map +1 -0
- package/dist/codegen/ibc/applications/interchain_accounts/controller/v1/tx.d.ts +108 -0
- package/dist/codegen/ibc/applications/interchain_accounts/controller/v1/tx.js +313 -0
- package/dist/codegen/ibc/applications/interchain_accounts/controller/v1/tx.js.map +1 -0
- package/dist/codegen/ibc/applications/interchain_accounts/genesis/v1/genesis.d.ts +150 -0
- package/dist/codegen/ibc/applications/interchain_accounts/genesis/v1/genesis.js +500 -0
- package/dist/codegen/ibc/applications/interchain_accounts/genesis/v1/genesis.js.map +1 -0
- package/dist/codegen/ibc/applications/interchain_accounts/host/v1/host.d.ts +34 -0
- package/dist/codegen/ibc/applications/interchain_accounts/host/v1/host.js +82 -0
- package/dist/codegen/ibc/applications/interchain_accounts/host/v1/host.js.map +1 -0
- package/dist/codegen/ibc/applications/interchain_accounts/host/v1/query.d.ts +47 -0
- package/dist/codegen/ibc/applications/interchain_accounts/host/v1/query.js +113 -0
- package/dist/codegen/ibc/applications/interchain_accounts/host/v1/query.js.map +1 -0
- package/dist/codegen/ibc/applications/interchain_accounts/v1/account.d.ts +29 -0
- package/dist/codegen/ibc/applications/interchain_accounts/v1/account.js +85 -0
- package/dist/codegen/ibc/applications/interchain_accounts/v1/account.js.map +1 -0
- package/dist/codegen/ibc/applications/interchain_accounts/v1/metadata.d.ts +49 -0
- package/dist/codegen/ibc/applications/interchain_accounts/v1/metadata.js +118 -0
- package/dist/codegen/ibc/applications/interchain_accounts/v1/metadata.js.map +1 -0
- package/dist/codegen/ibc/applications/interchain_accounts/v1/packet.d.ts +66 -0
- package/dist/codegen/ibc/applications/interchain_accounts/v1/packet.js +189 -0
- package/dist/codegen/ibc/applications/interchain_accounts/v1/packet.js.map +1 -0
- package/dist/codegen/ibc/applications/transfer/v1/authz.d.ts +67 -0
- package/dist/codegen/ibc/applications/transfer/v1/authz.js +177 -0
- package/dist/codegen/ibc/applications/transfer/v1/authz.js.map +1 -0
- package/dist/codegen/ibc/applications/transfer/v1/genesis.d.ts +29 -0
- package/dist/codegen/ibc/applications/transfer/v1/genesis.js +95 -0
- package/dist/codegen/ibc/applications/transfer/v1/genesis.js.map +1 -0
- package/dist/codegen/ibc/applications/transfer/v1/query.d.ts +282 -0
- package/dist/codegen/ibc/applications/transfer/v1/query.js +633 -0
- package/dist/codegen/ibc/applications/transfer/v1/query.js.map +1 -0
- package/dist/codegen/ibc/applications/transfer/v1/transfer.d.ts +80 -0
- package/dist/codegen/ibc/applications/transfer/v1/transfer.js +146 -0
- package/dist/codegen/ibc/applications/transfer/v1/transfer.js.map +1 -0
- package/dist/codegen/ibc/applications/transfer/v1/tx.d.ts +86 -0
- package/dist/codegen/ibc/applications/transfer/v1/tx.js +219 -0
- package/dist/codegen/ibc/applications/transfer/v1/tx.js.map +1 -0
- package/dist/codegen/ibc/applications/transfer/v2/packet.d.ts +45 -0
- package/dist/codegen/ibc/applications/transfer/v2/packet.js +102 -0
- package/dist/codegen/ibc/applications/transfer/v2/packet.js.map +1 -0
- package/dist/codegen/ibc/bundle.d.ts +2266 -122
- package/dist/codegen/ibc/bundle.js +124 -4
- package/dist/codegen/ibc/bundle.js.map +1 -1
- package/dist/codegen/ibc/core/channel/v1/genesis.d.ts +73 -0
- package/dist/codegen/ibc/core/channel/v1/genesis.js +280 -0
- package/dist/codegen/ibc/core/channel/v1/genesis.js.map +1 -0
- package/dist/codegen/ibc/core/channel/v1/query.d.ts +914 -0
- package/dist/codegen/ibc/core/channel/v1/query.js +2343 -0
- package/dist/codegen/ibc/core/channel/v1/query.js.map +1 -0
- package/dist/codegen/ibc/core/channel/v1/tx.d.ts +604 -0
- package/dist/codegen/ibc/core/channel/v1/tx.js +1744 -0
- package/dist/codegen/ibc/core/channel/v1/tx.js.map +1 -0
- package/dist/codegen/ibc/core/client/v1/genesis.d.ts +104 -0
- package/dist/codegen/ibc/core/client/v1/genesis.js +300 -0
- package/dist/codegen/ibc/core/client/v1/genesis.js.map +1 -0
- package/dist/codegen/ibc/core/client/v1/query.d.ts +577 -0
- package/dist/codegen/ibc/core/client/v1/query.js +1282 -0
- package/dist/codegen/ibc/core/client/v1/query.js.map +1 -0
- package/dist/codegen/ibc/core/client/v1/tx.d.ts +245 -0
- package/dist/codegen/ibc/core/client/v1/tx.js +586 -0
- package/dist/codegen/ibc/core/client/v1/tx.js.map +1 -0
- package/dist/codegen/ibc/core/commitment/v1/commitment.d.ts +128 -0
- package/dist/codegen/ibc/core/commitment/v1/commitment.js +258 -0
- package/dist/codegen/ibc/core/commitment/v1/commitment.js.map +1 -0
- package/dist/codegen/ibc/core/connection/v1/connection.d.ts +272 -0
- package/dist/codegen/ibc/core/connection/v1/connection.js +677 -0
- package/dist/codegen/ibc/core/connection/v1/connection.js.map +1 -0
- package/dist/codegen/ibc/core/connection/v1/genesis.d.ts +32 -0
- package/dist/codegen/ibc/core/connection/v1/genesis.js +121 -0
- package/dist/codegen/ibc/core/connection/v1/genesis.js.map +1 -0
- package/dist/codegen/ibc/core/connection/v1/query.d.ts +388 -0
- package/dist/codegen/ibc/core/connection/v1/query.js +951 -0
- package/dist/codegen/ibc/core/connection/v1/query.js.map +1 -0
- package/dist/codegen/ibc/core/connection/v1/tx.d.ts +286 -0
- package/dist/codegen/ibc/core/connection/v1/tx.js +842 -0
- package/dist/codegen/ibc/core/connection/v1/tx.js.map +1 -0
- package/dist/codegen/ibc/lightclients/localhost/v1/localhost.d.ts +35 -0
- package/dist/codegen/ibc/lightclients/localhost/v1/localhost.js +77 -0
- package/dist/codegen/ibc/lightclients/localhost/v1/localhost.js.map +1 -0
- package/dist/codegen/ibc/lightclients/solomachine/v1/solomachine.d.ts +549 -0
- package/dist/codegen/ibc/lightclients/solomachine/v1/solomachine.js +1519 -0
- package/dist/codegen/ibc/lightclients/solomachine/v1/solomachine.js.map +1 -0
- package/dist/codegen/ibc/lightclients/solomachine/v2/solomachine.d.ts +549 -0
- package/dist/codegen/ibc/lightclients/solomachine/v2/solomachine.js +1513 -0
- package/dist/codegen/ibc/lightclients/solomachine/v2/solomachine.js.map +1 -0
- package/dist/codegen/ibc/lightclients/tendermint/v1/tendermint.d.ts +231 -0
- package/dist/codegen/ibc/lightclients/tendermint/v1/tendermint.js +624 -0
- package/dist/codegen/ibc/lightclients/tendermint/v1/tendermint.js.map +1 -0
- package/dist/codegen/ics23/bundle.d.ts +154 -0
- package/dist/codegen/ics23/bundle.js +6 -0
- package/dist/codegen/ics23/bundle.js.map +1 -0
- package/dist/codegen/index.d.ts +1 -0
- package/dist/codegen/index.js +1 -0
- package/dist/codegen/index.js.map +1 -1
- package/dist/codegen/proofs.d.ts +569 -0
- package/dist/codegen/proofs.js +1435 -0
- package/dist/codegen/proofs.js.map +1 -0
- package/dist/codegen/tendermint/bundle.d.ts +716 -716
- package/dist/codegen/tendermint/bundle.js +22 -22
- package/dist/codegen/tendermint/bundle.js.map +1 -1
- package/package.json +7 -3
|
@@ -0,0 +1,677 @@
|
|
|
1
|
+
//@ts-nocheck
|
|
2
|
+
import { MerklePrefix, } from '../../commitment/v1/commitment.js';
|
|
3
|
+
import { BinaryReader, BinaryWriter } from '../../../../binary.js';
|
|
4
|
+
import { isSet } from '../../../../helpers.js';
|
|
5
|
+
/**
|
|
6
|
+
* State defines if a connection is in one of the following states:
|
|
7
|
+
* INIT, TRYOPEN, OPEN or UNINITIALIZED.
|
|
8
|
+
*/
|
|
9
|
+
export var State;
|
|
10
|
+
(function (State) {
|
|
11
|
+
/** STATE_UNINITIALIZED_UNSPECIFIED - Default State */
|
|
12
|
+
State[State["STATE_UNINITIALIZED_UNSPECIFIED"] = 0] = "STATE_UNINITIALIZED_UNSPECIFIED";
|
|
13
|
+
/** STATE_INIT - A connection end has just started the opening handshake. */
|
|
14
|
+
State[State["STATE_INIT"] = 1] = "STATE_INIT";
|
|
15
|
+
/**
|
|
16
|
+
* STATE_TRYOPEN - A connection end has acknowledged the handshake step on the counterparty
|
|
17
|
+
* chain.
|
|
18
|
+
*/
|
|
19
|
+
State[State["STATE_TRYOPEN"] = 2] = "STATE_TRYOPEN";
|
|
20
|
+
/** STATE_OPEN - A connection end has completed the handshake. */
|
|
21
|
+
State[State["STATE_OPEN"] = 3] = "STATE_OPEN";
|
|
22
|
+
State[State["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
23
|
+
})(State || (State = {}));
|
|
24
|
+
export const StateSDKType = State;
|
|
25
|
+
export function stateFromJSON(object) {
|
|
26
|
+
switch (object) {
|
|
27
|
+
case 0:
|
|
28
|
+
case 'STATE_UNINITIALIZED_UNSPECIFIED':
|
|
29
|
+
return State.STATE_UNINITIALIZED_UNSPECIFIED;
|
|
30
|
+
case 1:
|
|
31
|
+
case 'STATE_INIT':
|
|
32
|
+
return State.STATE_INIT;
|
|
33
|
+
case 2:
|
|
34
|
+
case 'STATE_TRYOPEN':
|
|
35
|
+
return State.STATE_TRYOPEN;
|
|
36
|
+
case 3:
|
|
37
|
+
case 'STATE_OPEN':
|
|
38
|
+
return State.STATE_OPEN;
|
|
39
|
+
case -1:
|
|
40
|
+
case 'UNRECOGNIZED':
|
|
41
|
+
default:
|
|
42
|
+
return State.UNRECOGNIZED;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
export function stateToJSON(object) {
|
|
46
|
+
switch (object) {
|
|
47
|
+
case State.STATE_UNINITIALIZED_UNSPECIFIED:
|
|
48
|
+
return 'STATE_UNINITIALIZED_UNSPECIFIED';
|
|
49
|
+
case State.STATE_INIT:
|
|
50
|
+
return 'STATE_INIT';
|
|
51
|
+
case State.STATE_TRYOPEN:
|
|
52
|
+
return 'STATE_TRYOPEN';
|
|
53
|
+
case State.STATE_OPEN:
|
|
54
|
+
return 'STATE_OPEN';
|
|
55
|
+
case State.UNRECOGNIZED:
|
|
56
|
+
default:
|
|
57
|
+
return 'UNRECOGNIZED';
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
function createBaseConnectionEnd() {
|
|
61
|
+
return {
|
|
62
|
+
clientId: '',
|
|
63
|
+
versions: [],
|
|
64
|
+
state: 0,
|
|
65
|
+
counterparty: Counterparty.fromPartial({}),
|
|
66
|
+
delayPeriod: BigInt(0),
|
|
67
|
+
};
|
|
68
|
+
}
|
|
69
|
+
export const ConnectionEnd = {
|
|
70
|
+
typeUrl: '/ibc.core.connection.v1.ConnectionEnd',
|
|
71
|
+
encode(message, writer = BinaryWriter.create()) {
|
|
72
|
+
if (message.clientId !== '') {
|
|
73
|
+
writer.uint32(10).string(message.clientId);
|
|
74
|
+
}
|
|
75
|
+
for (const v of message.versions) {
|
|
76
|
+
Version.encode(v, writer.uint32(18).fork()).ldelim();
|
|
77
|
+
}
|
|
78
|
+
if (message.state !== 0) {
|
|
79
|
+
writer.uint32(24).int32(message.state);
|
|
80
|
+
}
|
|
81
|
+
if (message.counterparty !== undefined) {
|
|
82
|
+
Counterparty.encode(message.counterparty, writer.uint32(34).fork()).ldelim();
|
|
83
|
+
}
|
|
84
|
+
if (message.delayPeriod !== BigInt(0)) {
|
|
85
|
+
writer.uint32(40).uint64(message.delayPeriod);
|
|
86
|
+
}
|
|
87
|
+
return writer;
|
|
88
|
+
},
|
|
89
|
+
decode(input, length) {
|
|
90
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
91
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
92
|
+
const message = createBaseConnectionEnd();
|
|
93
|
+
while (reader.pos < end) {
|
|
94
|
+
const tag = reader.uint32();
|
|
95
|
+
switch (tag >>> 3) {
|
|
96
|
+
case 1:
|
|
97
|
+
message.clientId = reader.string();
|
|
98
|
+
break;
|
|
99
|
+
case 2:
|
|
100
|
+
message.versions.push(Version.decode(reader, reader.uint32()));
|
|
101
|
+
break;
|
|
102
|
+
case 3:
|
|
103
|
+
message.state = reader.int32();
|
|
104
|
+
break;
|
|
105
|
+
case 4:
|
|
106
|
+
message.counterparty = Counterparty.decode(reader, reader.uint32());
|
|
107
|
+
break;
|
|
108
|
+
case 5:
|
|
109
|
+
message.delayPeriod = reader.uint64();
|
|
110
|
+
break;
|
|
111
|
+
default:
|
|
112
|
+
reader.skipType(tag & 7);
|
|
113
|
+
break;
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
return message;
|
|
117
|
+
},
|
|
118
|
+
fromJSON(object) {
|
|
119
|
+
return {
|
|
120
|
+
clientId: isSet(object.clientId) ? String(object.clientId) : '',
|
|
121
|
+
versions: Array.isArray(object?.versions)
|
|
122
|
+
? object.versions.map((e) => Version.fromJSON(e))
|
|
123
|
+
: [],
|
|
124
|
+
state: isSet(object.state) ? stateFromJSON(object.state) : -1,
|
|
125
|
+
counterparty: isSet(object.counterparty)
|
|
126
|
+
? Counterparty.fromJSON(object.counterparty)
|
|
127
|
+
: undefined,
|
|
128
|
+
delayPeriod: isSet(object.delayPeriod)
|
|
129
|
+
? BigInt(object.delayPeriod.toString())
|
|
130
|
+
: BigInt(0),
|
|
131
|
+
};
|
|
132
|
+
},
|
|
133
|
+
toJSON(message) {
|
|
134
|
+
const obj = {};
|
|
135
|
+
message.clientId !== undefined && (obj.clientId = message.clientId);
|
|
136
|
+
if (message.versions) {
|
|
137
|
+
obj.versions = message.versions.map(e => e ? Version.toJSON(e) : undefined);
|
|
138
|
+
}
|
|
139
|
+
else {
|
|
140
|
+
obj.versions = [];
|
|
141
|
+
}
|
|
142
|
+
message.state !== undefined && (obj.state = stateToJSON(message.state));
|
|
143
|
+
message.counterparty !== undefined &&
|
|
144
|
+
(obj.counterparty = message.counterparty
|
|
145
|
+
? Counterparty.toJSON(message.counterparty)
|
|
146
|
+
: undefined);
|
|
147
|
+
message.delayPeriod !== undefined &&
|
|
148
|
+
(obj.delayPeriod = (message.delayPeriod || BigInt(0)).toString());
|
|
149
|
+
return obj;
|
|
150
|
+
},
|
|
151
|
+
fromPartial(object) {
|
|
152
|
+
const message = createBaseConnectionEnd();
|
|
153
|
+
message.clientId = object.clientId ?? '';
|
|
154
|
+
message.versions = object.versions?.map(e => Version.fromPartial(e)) || [];
|
|
155
|
+
message.state = object.state ?? 0;
|
|
156
|
+
message.counterparty =
|
|
157
|
+
object.counterparty !== undefined && object.counterparty !== null
|
|
158
|
+
? Counterparty.fromPartial(object.counterparty)
|
|
159
|
+
: undefined;
|
|
160
|
+
message.delayPeriod =
|
|
161
|
+
object.delayPeriod !== undefined && object.delayPeriod !== null
|
|
162
|
+
? BigInt(object.delayPeriod.toString())
|
|
163
|
+
: BigInt(0);
|
|
164
|
+
return message;
|
|
165
|
+
},
|
|
166
|
+
fromProtoMsg(message) {
|
|
167
|
+
return ConnectionEnd.decode(message.value);
|
|
168
|
+
},
|
|
169
|
+
toProto(message) {
|
|
170
|
+
return ConnectionEnd.encode(message).finish();
|
|
171
|
+
},
|
|
172
|
+
toProtoMsg(message) {
|
|
173
|
+
return {
|
|
174
|
+
typeUrl: '/ibc.core.connection.v1.ConnectionEnd',
|
|
175
|
+
value: ConnectionEnd.encode(message).finish(),
|
|
176
|
+
};
|
|
177
|
+
},
|
|
178
|
+
};
|
|
179
|
+
function createBaseIdentifiedConnection() {
|
|
180
|
+
return {
|
|
181
|
+
id: '',
|
|
182
|
+
clientId: '',
|
|
183
|
+
versions: [],
|
|
184
|
+
state: 0,
|
|
185
|
+
counterparty: Counterparty.fromPartial({}),
|
|
186
|
+
delayPeriod: BigInt(0),
|
|
187
|
+
};
|
|
188
|
+
}
|
|
189
|
+
export const IdentifiedConnection = {
|
|
190
|
+
typeUrl: '/ibc.core.connection.v1.IdentifiedConnection',
|
|
191
|
+
encode(message, writer = BinaryWriter.create()) {
|
|
192
|
+
if (message.id !== '') {
|
|
193
|
+
writer.uint32(10).string(message.id);
|
|
194
|
+
}
|
|
195
|
+
if (message.clientId !== '') {
|
|
196
|
+
writer.uint32(18).string(message.clientId);
|
|
197
|
+
}
|
|
198
|
+
for (const v of message.versions) {
|
|
199
|
+
Version.encode(v, writer.uint32(26).fork()).ldelim();
|
|
200
|
+
}
|
|
201
|
+
if (message.state !== 0) {
|
|
202
|
+
writer.uint32(32).int32(message.state);
|
|
203
|
+
}
|
|
204
|
+
if (message.counterparty !== undefined) {
|
|
205
|
+
Counterparty.encode(message.counterparty, writer.uint32(42).fork()).ldelim();
|
|
206
|
+
}
|
|
207
|
+
if (message.delayPeriod !== BigInt(0)) {
|
|
208
|
+
writer.uint32(48).uint64(message.delayPeriod);
|
|
209
|
+
}
|
|
210
|
+
return writer;
|
|
211
|
+
},
|
|
212
|
+
decode(input, length) {
|
|
213
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
214
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
215
|
+
const message = createBaseIdentifiedConnection();
|
|
216
|
+
while (reader.pos < end) {
|
|
217
|
+
const tag = reader.uint32();
|
|
218
|
+
switch (tag >>> 3) {
|
|
219
|
+
case 1:
|
|
220
|
+
message.id = reader.string();
|
|
221
|
+
break;
|
|
222
|
+
case 2:
|
|
223
|
+
message.clientId = reader.string();
|
|
224
|
+
break;
|
|
225
|
+
case 3:
|
|
226
|
+
message.versions.push(Version.decode(reader, reader.uint32()));
|
|
227
|
+
break;
|
|
228
|
+
case 4:
|
|
229
|
+
message.state = reader.int32();
|
|
230
|
+
break;
|
|
231
|
+
case 5:
|
|
232
|
+
message.counterparty = Counterparty.decode(reader, reader.uint32());
|
|
233
|
+
break;
|
|
234
|
+
case 6:
|
|
235
|
+
message.delayPeriod = reader.uint64();
|
|
236
|
+
break;
|
|
237
|
+
default:
|
|
238
|
+
reader.skipType(tag & 7);
|
|
239
|
+
break;
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
return message;
|
|
243
|
+
},
|
|
244
|
+
fromJSON(object) {
|
|
245
|
+
return {
|
|
246
|
+
id: isSet(object.id) ? String(object.id) : '',
|
|
247
|
+
clientId: isSet(object.clientId) ? String(object.clientId) : '',
|
|
248
|
+
versions: Array.isArray(object?.versions)
|
|
249
|
+
? object.versions.map((e) => Version.fromJSON(e))
|
|
250
|
+
: [],
|
|
251
|
+
state: isSet(object.state) ? stateFromJSON(object.state) : -1,
|
|
252
|
+
counterparty: isSet(object.counterparty)
|
|
253
|
+
? Counterparty.fromJSON(object.counterparty)
|
|
254
|
+
: undefined,
|
|
255
|
+
delayPeriod: isSet(object.delayPeriod)
|
|
256
|
+
? BigInt(object.delayPeriod.toString())
|
|
257
|
+
: BigInt(0),
|
|
258
|
+
};
|
|
259
|
+
},
|
|
260
|
+
toJSON(message) {
|
|
261
|
+
const obj = {};
|
|
262
|
+
message.id !== undefined && (obj.id = message.id);
|
|
263
|
+
message.clientId !== undefined && (obj.clientId = message.clientId);
|
|
264
|
+
if (message.versions) {
|
|
265
|
+
obj.versions = message.versions.map(e => e ? Version.toJSON(e) : undefined);
|
|
266
|
+
}
|
|
267
|
+
else {
|
|
268
|
+
obj.versions = [];
|
|
269
|
+
}
|
|
270
|
+
message.state !== undefined && (obj.state = stateToJSON(message.state));
|
|
271
|
+
message.counterparty !== undefined &&
|
|
272
|
+
(obj.counterparty = message.counterparty
|
|
273
|
+
? Counterparty.toJSON(message.counterparty)
|
|
274
|
+
: undefined);
|
|
275
|
+
message.delayPeriod !== undefined &&
|
|
276
|
+
(obj.delayPeriod = (message.delayPeriod || BigInt(0)).toString());
|
|
277
|
+
return obj;
|
|
278
|
+
},
|
|
279
|
+
fromPartial(object) {
|
|
280
|
+
const message = createBaseIdentifiedConnection();
|
|
281
|
+
message.id = object.id ?? '';
|
|
282
|
+
message.clientId = object.clientId ?? '';
|
|
283
|
+
message.versions = object.versions?.map(e => Version.fromPartial(e)) || [];
|
|
284
|
+
message.state = object.state ?? 0;
|
|
285
|
+
message.counterparty =
|
|
286
|
+
object.counterparty !== undefined && object.counterparty !== null
|
|
287
|
+
? Counterparty.fromPartial(object.counterparty)
|
|
288
|
+
: undefined;
|
|
289
|
+
message.delayPeriod =
|
|
290
|
+
object.delayPeriod !== undefined && object.delayPeriod !== null
|
|
291
|
+
? BigInt(object.delayPeriod.toString())
|
|
292
|
+
: BigInt(0);
|
|
293
|
+
return message;
|
|
294
|
+
},
|
|
295
|
+
fromProtoMsg(message) {
|
|
296
|
+
return IdentifiedConnection.decode(message.value);
|
|
297
|
+
},
|
|
298
|
+
toProto(message) {
|
|
299
|
+
return IdentifiedConnection.encode(message).finish();
|
|
300
|
+
},
|
|
301
|
+
toProtoMsg(message) {
|
|
302
|
+
return {
|
|
303
|
+
typeUrl: '/ibc.core.connection.v1.IdentifiedConnection',
|
|
304
|
+
value: IdentifiedConnection.encode(message).finish(),
|
|
305
|
+
};
|
|
306
|
+
},
|
|
307
|
+
};
|
|
308
|
+
function createBaseCounterparty() {
|
|
309
|
+
return {
|
|
310
|
+
clientId: '',
|
|
311
|
+
connectionId: '',
|
|
312
|
+
prefix: MerklePrefix.fromPartial({}),
|
|
313
|
+
};
|
|
314
|
+
}
|
|
315
|
+
export const Counterparty = {
|
|
316
|
+
typeUrl: '/ibc.core.connection.v1.Counterparty',
|
|
317
|
+
encode(message, writer = BinaryWriter.create()) {
|
|
318
|
+
if (message.clientId !== '') {
|
|
319
|
+
writer.uint32(10).string(message.clientId);
|
|
320
|
+
}
|
|
321
|
+
if (message.connectionId !== '') {
|
|
322
|
+
writer.uint32(18).string(message.connectionId);
|
|
323
|
+
}
|
|
324
|
+
if (message.prefix !== undefined) {
|
|
325
|
+
MerklePrefix.encode(message.prefix, writer.uint32(26).fork()).ldelim();
|
|
326
|
+
}
|
|
327
|
+
return writer;
|
|
328
|
+
},
|
|
329
|
+
decode(input, length) {
|
|
330
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
331
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
332
|
+
const message = createBaseCounterparty();
|
|
333
|
+
while (reader.pos < end) {
|
|
334
|
+
const tag = reader.uint32();
|
|
335
|
+
switch (tag >>> 3) {
|
|
336
|
+
case 1:
|
|
337
|
+
message.clientId = reader.string();
|
|
338
|
+
break;
|
|
339
|
+
case 2:
|
|
340
|
+
message.connectionId = reader.string();
|
|
341
|
+
break;
|
|
342
|
+
case 3:
|
|
343
|
+
message.prefix = MerklePrefix.decode(reader, reader.uint32());
|
|
344
|
+
break;
|
|
345
|
+
default:
|
|
346
|
+
reader.skipType(tag & 7);
|
|
347
|
+
break;
|
|
348
|
+
}
|
|
349
|
+
}
|
|
350
|
+
return message;
|
|
351
|
+
},
|
|
352
|
+
fromJSON(object) {
|
|
353
|
+
return {
|
|
354
|
+
clientId: isSet(object.clientId) ? String(object.clientId) : '',
|
|
355
|
+
connectionId: isSet(object.connectionId)
|
|
356
|
+
? String(object.connectionId)
|
|
357
|
+
: '',
|
|
358
|
+
prefix: isSet(object.prefix)
|
|
359
|
+
? MerklePrefix.fromJSON(object.prefix)
|
|
360
|
+
: undefined,
|
|
361
|
+
};
|
|
362
|
+
},
|
|
363
|
+
toJSON(message) {
|
|
364
|
+
const obj = {};
|
|
365
|
+
message.clientId !== undefined && (obj.clientId = message.clientId);
|
|
366
|
+
message.connectionId !== undefined &&
|
|
367
|
+
(obj.connectionId = message.connectionId);
|
|
368
|
+
message.prefix !== undefined &&
|
|
369
|
+
(obj.prefix = message.prefix
|
|
370
|
+
? MerklePrefix.toJSON(message.prefix)
|
|
371
|
+
: undefined);
|
|
372
|
+
return obj;
|
|
373
|
+
},
|
|
374
|
+
fromPartial(object) {
|
|
375
|
+
const message = createBaseCounterparty();
|
|
376
|
+
message.clientId = object.clientId ?? '';
|
|
377
|
+
message.connectionId = object.connectionId ?? '';
|
|
378
|
+
message.prefix =
|
|
379
|
+
object.prefix !== undefined && object.prefix !== null
|
|
380
|
+
? MerklePrefix.fromPartial(object.prefix)
|
|
381
|
+
: undefined;
|
|
382
|
+
return message;
|
|
383
|
+
},
|
|
384
|
+
fromProtoMsg(message) {
|
|
385
|
+
return Counterparty.decode(message.value);
|
|
386
|
+
},
|
|
387
|
+
toProto(message) {
|
|
388
|
+
return Counterparty.encode(message).finish();
|
|
389
|
+
},
|
|
390
|
+
toProtoMsg(message) {
|
|
391
|
+
return {
|
|
392
|
+
typeUrl: '/ibc.core.connection.v1.Counterparty',
|
|
393
|
+
value: Counterparty.encode(message).finish(),
|
|
394
|
+
};
|
|
395
|
+
},
|
|
396
|
+
};
|
|
397
|
+
function createBaseClientPaths() {
|
|
398
|
+
return {
|
|
399
|
+
paths: [],
|
|
400
|
+
};
|
|
401
|
+
}
|
|
402
|
+
export const ClientPaths = {
|
|
403
|
+
typeUrl: '/ibc.core.connection.v1.ClientPaths',
|
|
404
|
+
encode(message, writer = BinaryWriter.create()) {
|
|
405
|
+
for (const v of message.paths) {
|
|
406
|
+
writer.uint32(10).string(v);
|
|
407
|
+
}
|
|
408
|
+
return writer;
|
|
409
|
+
},
|
|
410
|
+
decode(input, length) {
|
|
411
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
412
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
413
|
+
const message = createBaseClientPaths();
|
|
414
|
+
while (reader.pos < end) {
|
|
415
|
+
const tag = reader.uint32();
|
|
416
|
+
switch (tag >>> 3) {
|
|
417
|
+
case 1:
|
|
418
|
+
message.paths.push(reader.string());
|
|
419
|
+
break;
|
|
420
|
+
default:
|
|
421
|
+
reader.skipType(tag & 7);
|
|
422
|
+
break;
|
|
423
|
+
}
|
|
424
|
+
}
|
|
425
|
+
return message;
|
|
426
|
+
},
|
|
427
|
+
fromJSON(object) {
|
|
428
|
+
return {
|
|
429
|
+
paths: Array.isArray(object?.paths)
|
|
430
|
+
? object.paths.map((e) => String(e))
|
|
431
|
+
: [],
|
|
432
|
+
};
|
|
433
|
+
},
|
|
434
|
+
toJSON(message) {
|
|
435
|
+
const obj = {};
|
|
436
|
+
if (message.paths) {
|
|
437
|
+
obj.paths = message.paths.map(e => e);
|
|
438
|
+
}
|
|
439
|
+
else {
|
|
440
|
+
obj.paths = [];
|
|
441
|
+
}
|
|
442
|
+
return obj;
|
|
443
|
+
},
|
|
444
|
+
fromPartial(object) {
|
|
445
|
+
const message = createBaseClientPaths();
|
|
446
|
+
message.paths = object.paths?.map(e => e) || [];
|
|
447
|
+
return message;
|
|
448
|
+
},
|
|
449
|
+
fromProtoMsg(message) {
|
|
450
|
+
return ClientPaths.decode(message.value);
|
|
451
|
+
},
|
|
452
|
+
toProto(message) {
|
|
453
|
+
return ClientPaths.encode(message).finish();
|
|
454
|
+
},
|
|
455
|
+
toProtoMsg(message) {
|
|
456
|
+
return {
|
|
457
|
+
typeUrl: '/ibc.core.connection.v1.ClientPaths',
|
|
458
|
+
value: ClientPaths.encode(message).finish(),
|
|
459
|
+
};
|
|
460
|
+
},
|
|
461
|
+
};
|
|
462
|
+
function createBaseConnectionPaths() {
|
|
463
|
+
return {
|
|
464
|
+
clientId: '',
|
|
465
|
+
paths: [],
|
|
466
|
+
};
|
|
467
|
+
}
|
|
468
|
+
export const ConnectionPaths = {
|
|
469
|
+
typeUrl: '/ibc.core.connection.v1.ConnectionPaths',
|
|
470
|
+
encode(message, writer = BinaryWriter.create()) {
|
|
471
|
+
if (message.clientId !== '') {
|
|
472
|
+
writer.uint32(10).string(message.clientId);
|
|
473
|
+
}
|
|
474
|
+
for (const v of message.paths) {
|
|
475
|
+
writer.uint32(18).string(v);
|
|
476
|
+
}
|
|
477
|
+
return writer;
|
|
478
|
+
},
|
|
479
|
+
decode(input, length) {
|
|
480
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
481
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
482
|
+
const message = createBaseConnectionPaths();
|
|
483
|
+
while (reader.pos < end) {
|
|
484
|
+
const tag = reader.uint32();
|
|
485
|
+
switch (tag >>> 3) {
|
|
486
|
+
case 1:
|
|
487
|
+
message.clientId = reader.string();
|
|
488
|
+
break;
|
|
489
|
+
case 2:
|
|
490
|
+
message.paths.push(reader.string());
|
|
491
|
+
break;
|
|
492
|
+
default:
|
|
493
|
+
reader.skipType(tag & 7);
|
|
494
|
+
break;
|
|
495
|
+
}
|
|
496
|
+
}
|
|
497
|
+
return message;
|
|
498
|
+
},
|
|
499
|
+
fromJSON(object) {
|
|
500
|
+
return {
|
|
501
|
+
clientId: isSet(object.clientId) ? String(object.clientId) : '',
|
|
502
|
+
paths: Array.isArray(object?.paths)
|
|
503
|
+
? object.paths.map((e) => String(e))
|
|
504
|
+
: [],
|
|
505
|
+
};
|
|
506
|
+
},
|
|
507
|
+
toJSON(message) {
|
|
508
|
+
const obj = {};
|
|
509
|
+
message.clientId !== undefined && (obj.clientId = message.clientId);
|
|
510
|
+
if (message.paths) {
|
|
511
|
+
obj.paths = message.paths.map(e => e);
|
|
512
|
+
}
|
|
513
|
+
else {
|
|
514
|
+
obj.paths = [];
|
|
515
|
+
}
|
|
516
|
+
return obj;
|
|
517
|
+
},
|
|
518
|
+
fromPartial(object) {
|
|
519
|
+
const message = createBaseConnectionPaths();
|
|
520
|
+
message.clientId = object.clientId ?? '';
|
|
521
|
+
message.paths = object.paths?.map(e => e) || [];
|
|
522
|
+
return message;
|
|
523
|
+
},
|
|
524
|
+
fromProtoMsg(message) {
|
|
525
|
+
return ConnectionPaths.decode(message.value);
|
|
526
|
+
},
|
|
527
|
+
toProto(message) {
|
|
528
|
+
return ConnectionPaths.encode(message).finish();
|
|
529
|
+
},
|
|
530
|
+
toProtoMsg(message) {
|
|
531
|
+
return {
|
|
532
|
+
typeUrl: '/ibc.core.connection.v1.ConnectionPaths',
|
|
533
|
+
value: ConnectionPaths.encode(message).finish(),
|
|
534
|
+
};
|
|
535
|
+
},
|
|
536
|
+
};
|
|
537
|
+
function createBaseVersion() {
|
|
538
|
+
return {
|
|
539
|
+
identifier: '',
|
|
540
|
+
features: [],
|
|
541
|
+
};
|
|
542
|
+
}
|
|
543
|
+
export const Version = {
|
|
544
|
+
typeUrl: '/ibc.core.connection.v1.Version',
|
|
545
|
+
encode(message, writer = BinaryWriter.create()) {
|
|
546
|
+
if (message.identifier !== '') {
|
|
547
|
+
writer.uint32(10).string(message.identifier);
|
|
548
|
+
}
|
|
549
|
+
for (const v of message.features) {
|
|
550
|
+
writer.uint32(18).string(v);
|
|
551
|
+
}
|
|
552
|
+
return writer;
|
|
553
|
+
},
|
|
554
|
+
decode(input, length) {
|
|
555
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
556
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
557
|
+
const message = createBaseVersion();
|
|
558
|
+
while (reader.pos < end) {
|
|
559
|
+
const tag = reader.uint32();
|
|
560
|
+
switch (tag >>> 3) {
|
|
561
|
+
case 1:
|
|
562
|
+
message.identifier = reader.string();
|
|
563
|
+
break;
|
|
564
|
+
case 2:
|
|
565
|
+
message.features.push(reader.string());
|
|
566
|
+
break;
|
|
567
|
+
default:
|
|
568
|
+
reader.skipType(tag & 7);
|
|
569
|
+
break;
|
|
570
|
+
}
|
|
571
|
+
}
|
|
572
|
+
return message;
|
|
573
|
+
},
|
|
574
|
+
fromJSON(object) {
|
|
575
|
+
return {
|
|
576
|
+
identifier: isSet(object.identifier) ? String(object.identifier) : '',
|
|
577
|
+
features: Array.isArray(object?.features)
|
|
578
|
+
? object.features.map((e) => String(e))
|
|
579
|
+
: [],
|
|
580
|
+
};
|
|
581
|
+
},
|
|
582
|
+
toJSON(message) {
|
|
583
|
+
const obj = {};
|
|
584
|
+
message.identifier !== undefined && (obj.identifier = message.identifier);
|
|
585
|
+
if (message.features) {
|
|
586
|
+
obj.features = message.features.map(e => e);
|
|
587
|
+
}
|
|
588
|
+
else {
|
|
589
|
+
obj.features = [];
|
|
590
|
+
}
|
|
591
|
+
return obj;
|
|
592
|
+
},
|
|
593
|
+
fromPartial(object) {
|
|
594
|
+
const message = createBaseVersion();
|
|
595
|
+
message.identifier = object.identifier ?? '';
|
|
596
|
+
message.features = object.features?.map(e => e) || [];
|
|
597
|
+
return message;
|
|
598
|
+
},
|
|
599
|
+
fromProtoMsg(message) {
|
|
600
|
+
return Version.decode(message.value);
|
|
601
|
+
},
|
|
602
|
+
toProto(message) {
|
|
603
|
+
return Version.encode(message).finish();
|
|
604
|
+
},
|
|
605
|
+
toProtoMsg(message) {
|
|
606
|
+
return {
|
|
607
|
+
typeUrl: '/ibc.core.connection.v1.Version',
|
|
608
|
+
value: Version.encode(message).finish(),
|
|
609
|
+
};
|
|
610
|
+
},
|
|
611
|
+
};
|
|
612
|
+
function createBaseParams() {
|
|
613
|
+
return {
|
|
614
|
+
maxExpectedTimePerBlock: BigInt(0),
|
|
615
|
+
};
|
|
616
|
+
}
|
|
617
|
+
export const Params = {
|
|
618
|
+
typeUrl: '/ibc.core.connection.v1.Params',
|
|
619
|
+
encode(message, writer = BinaryWriter.create()) {
|
|
620
|
+
if (message.maxExpectedTimePerBlock !== BigInt(0)) {
|
|
621
|
+
writer.uint32(8).uint64(message.maxExpectedTimePerBlock);
|
|
622
|
+
}
|
|
623
|
+
return writer;
|
|
624
|
+
},
|
|
625
|
+
decode(input, length) {
|
|
626
|
+
const reader = input instanceof BinaryReader ? input : new BinaryReader(input);
|
|
627
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
628
|
+
const message = createBaseParams();
|
|
629
|
+
while (reader.pos < end) {
|
|
630
|
+
const tag = reader.uint32();
|
|
631
|
+
switch (tag >>> 3) {
|
|
632
|
+
case 1:
|
|
633
|
+
message.maxExpectedTimePerBlock = reader.uint64();
|
|
634
|
+
break;
|
|
635
|
+
default:
|
|
636
|
+
reader.skipType(tag & 7);
|
|
637
|
+
break;
|
|
638
|
+
}
|
|
639
|
+
}
|
|
640
|
+
return message;
|
|
641
|
+
},
|
|
642
|
+
fromJSON(object) {
|
|
643
|
+
return {
|
|
644
|
+
maxExpectedTimePerBlock: isSet(object.maxExpectedTimePerBlock)
|
|
645
|
+
? BigInt(object.maxExpectedTimePerBlock.toString())
|
|
646
|
+
: BigInt(0),
|
|
647
|
+
};
|
|
648
|
+
},
|
|
649
|
+
toJSON(message) {
|
|
650
|
+
const obj = {};
|
|
651
|
+
message.maxExpectedTimePerBlock !== undefined &&
|
|
652
|
+
(obj.maxExpectedTimePerBlock = (message.maxExpectedTimePerBlock || BigInt(0)).toString());
|
|
653
|
+
return obj;
|
|
654
|
+
},
|
|
655
|
+
fromPartial(object) {
|
|
656
|
+
const message = createBaseParams();
|
|
657
|
+
message.maxExpectedTimePerBlock =
|
|
658
|
+
object.maxExpectedTimePerBlock !== undefined &&
|
|
659
|
+
object.maxExpectedTimePerBlock !== null
|
|
660
|
+
? BigInt(object.maxExpectedTimePerBlock.toString())
|
|
661
|
+
: BigInt(0);
|
|
662
|
+
return message;
|
|
663
|
+
},
|
|
664
|
+
fromProtoMsg(message) {
|
|
665
|
+
return Params.decode(message.value);
|
|
666
|
+
},
|
|
667
|
+
toProto(message) {
|
|
668
|
+
return Params.encode(message).finish();
|
|
669
|
+
},
|
|
670
|
+
toProtoMsg(message) {
|
|
671
|
+
return {
|
|
672
|
+
typeUrl: '/ibc.core.connection.v1.Params',
|
|
673
|
+
value: Params.encode(message).finish(),
|
|
674
|
+
};
|
|
675
|
+
},
|
|
676
|
+
};
|
|
677
|
+
//# sourceMappingURL=connection.js.map
|