@xpla/xplajs 1.9.0-rc0 → 1.9.1
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/binary.cjs +1 -1
- package/dist/binary.d.ts +1 -1
- package/dist/binary.js +1 -1
- package/dist/google/protobuf/any.cjs +77 -22
- package/dist/google/protobuf/any.d.ts +296 -133
- package/dist/google/protobuf/any.js +77 -22
- package/dist/registry.cjs +1 -1
- package/dist/registry.d.ts +1 -1
- package/dist/registry.js +1 -1
- package/dist/utf8.cjs +1 -1
- package/dist/utf8.d.ts +1 -1
- package/dist/utf8.js +1 -1
- package/dist/varint.cjs +1 -1
- package/dist/varint.d.ts +1 -1
- package/dist/varint.js +1 -1
- package/dist/xpla/rpc.query.cjs +1 -1
- package/dist/xpla/rpc.query.js +2 -2
- package/package.json +18 -16
package/dist/binary.cjs
CHANGED
|
@@ -4,7 +4,7 @@ const require_varint = require('./varint.cjs');
|
|
|
4
4
|
|
|
5
5
|
//#region src/binary.ts
|
|
6
6
|
/**
|
|
7
|
-
* This file and any referenced files were automatically generated by @hyperweb/telescope@
|
|
7
|
+
* This file and any referenced files were automatically generated by @hyperweb/telescope@2.2.4
|
|
8
8
|
* DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
|
|
9
9
|
* and run the transpile command or npm scripts command that is used to regenerate this bundle.
|
|
10
10
|
*/
|
package/dist/binary.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
//#region src/binary.d.ts
|
|
2
2
|
/**
|
|
3
|
-
* This file and any referenced files were automatically generated by @hyperweb/telescope@
|
|
3
|
+
* This file and any referenced files were automatically generated by @hyperweb/telescope@2.2.4
|
|
4
4
|
* DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
|
|
5
5
|
* and run the transpile command or npm scripts command that is used to regenerate this bundle.
|
|
6
6
|
*/
|
package/dist/binary.js
CHANGED
|
@@ -3,7 +3,7 @@ import { int64FromString, int64Length, int64ToString, readInt32, readUInt32, uIn
|
|
|
3
3
|
|
|
4
4
|
//#region src/binary.ts
|
|
5
5
|
/**
|
|
6
|
-
* This file and any referenced files were automatically generated by @hyperweb/telescope@
|
|
6
|
+
* This file and any referenced files were automatically generated by @hyperweb/telescope@2.2.4
|
|
7
7
|
* DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
|
|
8
8
|
* and run the transpile command or npm scripts command that is used to regenerate this bundle.
|
|
9
9
|
*/
|
|
@@ -12,33 +12,88 @@ function createBaseAny() {
|
|
|
12
12
|
* `Any` contains an arbitrary serialized protocol buffer message along with a
|
|
13
13
|
* URL that describes the type of the serialized message.
|
|
14
14
|
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
* described on the `type_url` field.
|
|
15
|
+
* Protobuf library provides support to pack/unpack Any values in the form
|
|
16
|
+
* of utility functions or additional generated methods of the Any type.
|
|
18
17
|
*
|
|
19
|
-
*
|
|
18
|
+
* Example 1: Pack and unpack a message in C++.
|
|
20
19
|
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
20
|
+
* Foo foo = ...;
|
|
21
|
+
* Any any;
|
|
22
|
+
* any.PackFrom(foo);
|
|
23
|
+
* ...
|
|
24
|
+
* if (any.UnpackTo(&foo)) {
|
|
25
|
+
* ...
|
|
26
|
+
* }
|
|
28
27
|
*
|
|
29
|
-
*
|
|
28
|
+
* Example 2: Pack and unpack a message in Java.
|
|
30
29
|
*
|
|
31
|
-
*
|
|
32
|
-
*
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
36
|
-
*
|
|
37
|
-
*
|
|
30
|
+
* Foo foo = ...;
|
|
31
|
+
* Any any = Any.pack(foo);
|
|
32
|
+
* ...
|
|
33
|
+
* if (any.is(Foo.class)) {
|
|
34
|
+
* foo = any.unpack(Foo.class);
|
|
35
|
+
* }
|
|
36
|
+
* // or ...
|
|
37
|
+
* if (any.isSameTypeAs(Foo.getDefaultInstance())) {
|
|
38
|
+
* foo = any.unpack(Foo.getDefaultInstance());
|
|
39
|
+
* }
|
|
38
40
|
*
|
|
39
|
-
*
|
|
40
|
-
*
|
|
41
|
-
*
|
|
41
|
+
* Example 3: Pack and unpack a message in Python.
|
|
42
|
+
*
|
|
43
|
+
* foo = Foo(...)
|
|
44
|
+
* any = Any()
|
|
45
|
+
* any.Pack(foo)
|
|
46
|
+
* ...
|
|
47
|
+
* if any.Is(Foo.DESCRIPTOR):
|
|
48
|
+
* any.Unpack(foo)
|
|
49
|
+
* ...
|
|
50
|
+
*
|
|
51
|
+
* Example 4: Pack and unpack a message in Go
|
|
52
|
+
*
|
|
53
|
+
* foo := &pb.Foo{...}
|
|
54
|
+
* any, err := anypb.New(foo)
|
|
55
|
+
* if err != nil {
|
|
56
|
+
* ...
|
|
57
|
+
* }
|
|
58
|
+
* ...
|
|
59
|
+
* foo := &pb.Foo{}
|
|
60
|
+
* if err := any.UnmarshalTo(foo); err != nil {
|
|
61
|
+
* ...
|
|
62
|
+
* }
|
|
63
|
+
*
|
|
64
|
+
* The pack methods provided by protobuf library will by default use
|
|
65
|
+
* 'type.googleapis.com/full.type.name' as the type URL and the unpack
|
|
66
|
+
* methods only use the fully qualified type name after the last '/'
|
|
67
|
+
* in the type URL, for example "foo.bar.com/x/y.z" will yield type
|
|
68
|
+
* name "y.z".
|
|
69
|
+
*
|
|
70
|
+
* JSON
|
|
71
|
+
* ====
|
|
72
|
+
* The JSON representation of an `Any` value uses the regular
|
|
73
|
+
* representation of the deserialized, embedded message, with an
|
|
74
|
+
* additional field `@type` which contains the type URL. Example:
|
|
75
|
+
*
|
|
76
|
+
* package google.profile;
|
|
77
|
+
* message Person {
|
|
78
|
+
* string first_name = 1;
|
|
79
|
+
* string last_name = 2;
|
|
80
|
+
* }
|
|
81
|
+
*
|
|
82
|
+
* {
|
|
83
|
+
* "@type": "type.googleapis.com/google.profile.Person",
|
|
84
|
+
* "firstName": <string>,
|
|
85
|
+
* "lastName": <string>
|
|
86
|
+
* }
|
|
87
|
+
*
|
|
88
|
+
* If the embedded message type is well-known and has a custom JSON
|
|
89
|
+
* representation, that representation will be embedded adding a field
|
|
90
|
+
* `value` which holds the custom JSON in addition to the `@type`
|
|
91
|
+
* field. Example (for message [google.protobuf.Duration][]):
|
|
92
|
+
*
|
|
93
|
+
* {
|
|
94
|
+
* "@type": "type.googleapis.com/google.protobuf.Duration",
|
|
95
|
+
* "value": "1.212s"
|
|
96
|
+
* }
|
|
42
97
|
* @name Any
|
|
43
98
|
* @package google.protobuf
|
|
44
99
|
* @see proto type: google.protobuf.Any
|
|
@@ -6,72 +6,126 @@ import { DeepPartial } from "../../helpers.js";
|
|
|
6
6
|
* `Any` contains an arbitrary serialized protocol buffer message along with a
|
|
7
7
|
* URL that describes the type of the serialized message.
|
|
8
8
|
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
*
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
9
|
+
* Protobuf library provides support to pack/unpack Any values in the form
|
|
10
|
+
* of utility functions or additional generated methods of the Any type.
|
|
11
|
+
*
|
|
12
|
+
* Example 1: Pack and unpack a message in C++.
|
|
13
|
+
*
|
|
14
|
+
* Foo foo = ...;
|
|
15
|
+
* Any any;
|
|
16
|
+
* any.PackFrom(foo);
|
|
17
|
+
* ...
|
|
18
|
+
* if (any.UnpackTo(&foo)) {
|
|
19
|
+
* ...
|
|
20
|
+
* }
|
|
21
|
+
*
|
|
22
|
+
* Example 2: Pack and unpack a message in Java.
|
|
23
|
+
*
|
|
24
|
+
* Foo foo = ...;
|
|
25
|
+
* Any any = Any.pack(foo);
|
|
26
|
+
* ...
|
|
27
|
+
* if (any.is(Foo.class)) {
|
|
28
|
+
* foo = any.unpack(Foo.class);
|
|
29
|
+
* }
|
|
30
|
+
* // or ...
|
|
31
|
+
* if (any.isSameTypeAs(Foo.getDefaultInstance())) {
|
|
32
|
+
* foo = any.unpack(Foo.getDefaultInstance());
|
|
33
|
+
* }
|
|
34
|
+
*
|
|
35
|
+
* Example 3: Pack and unpack a message in Python.
|
|
36
|
+
*
|
|
37
|
+
* foo = Foo(...)
|
|
38
|
+
* any = Any()
|
|
39
|
+
* any.Pack(foo)
|
|
40
|
+
* ...
|
|
41
|
+
* if any.Is(Foo.DESCRIPTOR):
|
|
42
|
+
* any.Unpack(foo)
|
|
43
|
+
* ...
|
|
44
|
+
*
|
|
45
|
+
* Example 4: Pack and unpack a message in Go
|
|
46
|
+
*
|
|
47
|
+
* foo := &pb.Foo{...}
|
|
48
|
+
* any, err := anypb.New(foo)
|
|
49
|
+
* if err != nil {
|
|
50
|
+
* ...
|
|
51
|
+
* }
|
|
52
|
+
* ...
|
|
53
|
+
* foo := &pb.Foo{}
|
|
54
|
+
* if err := any.UnmarshalTo(foo); err != nil {
|
|
55
|
+
* ...
|
|
56
|
+
* }
|
|
57
|
+
*
|
|
58
|
+
* The pack methods provided by protobuf library will by default use
|
|
59
|
+
* 'type.googleapis.com/full.type.name' as the type URL and the unpack
|
|
60
|
+
* methods only use the fully qualified type name after the last '/'
|
|
61
|
+
* in the type URL, for example "foo.bar.com/x/y.z" will yield type
|
|
62
|
+
* name "y.z".
|
|
63
|
+
*
|
|
64
|
+
* JSON
|
|
65
|
+
* ====
|
|
66
|
+
* The JSON representation of an `Any` value uses the regular
|
|
67
|
+
* representation of the deserialized, embedded message, with an
|
|
68
|
+
* additional field `@type` which contains the type URL. Example:
|
|
69
|
+
*
|
|
70
|
+
* package google.profile;
|
|
71
|
+
* message Person {
|
|
72
|
+
* string first_name = 1;
|
|
73
|
+
* string last_name = 2;
|
|
74
|
+
* }
|
|
75
|
+
*
|
|
76
|
+
* {
|
|
77
|
+
* "@type": "type.googleapis.com/google.profile.Person",
|
|
78
|
+
* "firstName": <string>,
|
|
79
|
+
* "lastName": <string>
|
|
80
|
+
* }
|
|
81
|
+
*
|
|
82
|
+
* If the embedded message type is well-known and has a custom JSON
|
|
83
|
+
* representation, that representation will be embedded adding a field
|
|
84
|
+
* `value` which holds the custom JSON in addition to the `@type`
|
|
85
|
+
* field. Example (for message [google.protobuf.Duration][]):
|
|
86
|
+
*
|
|
87
|
+
* {
|
|
88
|
+
* "@type": "type.googleapis.com/google.protobuf.Duration",
|
|
89
|
+
* "value": "1.212s"
|
|
90
|
+
* }
|
|
36
91
|
* @name Any
|
|
37
92
|
* @package google.protobuf
|
|
38
93
|
* @see proto type: google.protobuf.Any
|
|
39
94
|
*/
|
|
40
95
|
interface Any {
|
|
41
96
|
/**
|
|
42
|
-
*
|
|
43
|
-
*
|
|
97
|
+
* A URL/resource name that uniquely identifies the type of the serialized
|
|
98
|
+
* protocol buffer message. This string must contain at least
|
|
99
|
+
* one "/" character. The last segment of the URL's path must represent
|
|
100
|
+
* the fully qualified name of the type (as in
|
|
101
|
+
* `path/google.protobuf.Duration`). The name should be in a canonical form
|
|
102
|
+
* (e.g., leading "." is not accepted).
|
|
44
103
|
*
|
|
45
|
-
*
|
|
104
|
+
* In practice, teams usually precompile into the binary all types that they
|
|
105
|
+
* expect it to use in the context of Any. However, for URLs which use the
|
|
106
|
+
* scheme `http`, `https`, or no scheme, one can optionally set up a type
|
|
107
|
+
* server that maps type URLs to message definitions as follows:
|
|
46
108
|
*
|
|
47
|
-
*
|
|
48
|
-
*
|
|
49
|
-
*
|
|
50
|
-
*
|
|
109
|
+
* * If no scheme is provided, `https` is assumed.
|
|
110
|
+
* * An HTTP GET on the URL must yield a [google.protobuf.Type][]
|
|
111
|
+
* value in binary format, or produce an error.
|
|
112
|
+
* * Applications are allowed to cache lookup results based on the
|
|
113
|
+
* URL, or have them precompiled into a binary to avoid any
|
|
114
|
+
* lookup. Therefore, binary compatibility needs to be preserved
|
|
115
|
+
* on changes to types. (Use versioned type names to manage
|
|
116
|
+
* breaking changes.)
|
|
51
117
|
*
|
|
52
|
-
*
|
|
53
|
-
*
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
* the type, and URIs containing it are not expected to respond to any
|
|
57
|
-
* requests.
|
|
118
|
+
* Note: this functionality is not currently available in the official
|
|
119
|
+
* protobuf release, and it is not used for type URLs beginning with
|
|
120
|
+
* type.googleapis.com. As of May 2023, there are no widely used type server
|
|
121
|
+
* implementations and no plans to implement one.
|
|
58
122
|
*
|
|
59
|
-
*
|
|
60
|
-
*
|
|
61
|
-
* must consist only of alphanumeric characters, percent-encoded escapes, and
|
|
62
|
-
* characters in the following set (not including the outer backticks):
|
|
63
|
-
* `/-.~_!$&()*+,;=`. Despite our allowing percent encodings, implementations
|
|
64
|
-
* should not unescape them to prevent confusion with existing parsers. For
|
|
65
|
-
* example, `type.googleapis.com%2FFoo` should be rejected.
|
|
66
|
-
*
|
|
67
|
-
* In the original design of `Any`, the possibility of launching a type
|
|
68
|
-
* resolution service at these type URLs was considered but Protobuf never
|
|
69
|
-
* implemented one and considers contacting these URLs to be problematic and
|
|
70
|
-
* a potential security issue. Do not attempt to contact type URLs.
|
|
123
|
+
* Schemes other than `http`, `https` (or the empty scheme) might be
|
|
124
|
+
* used with implementation specific semantics.
|
|
71
125
|
*/
|
|
72
126
|
typeUrl: string;
|
|
73
127
|
/**
|
|
74
|
-
*
|
|
128
|
+
* Must be a valid serialized protocol buffer of the above specified type.
|
|
75
129
|
*/
|
|
76
130
|
value: Uint8Array;
|
|
77
131
|
}
|
|
@@ -83,72 +137,126 @@ interface AnyProtoMsg {
|
|
|
83
137
|
* `Any` contains an arbitrary serialized protocol buffer message along with a
|
|
84
138
|
* URL that describes the type of the serialized message.
|
|
85
139
|
*
|
|
86
|
-
*
|
|
87
|
-
*
|
|
88
|
-
*
|
|
89
|
-
*
|
|
90
|
-
*
|
|
91
|
-
*
|
|
92
|
-
*
|
|
93
|
-
*
|
|
94
|
-
*
|
|
95
|
-
*
|
|
96
|
-
*
|
|
97
|
-
*
|
|
98
|
-
*
|
|
99
|
-
*
|
|
100
|
-
*
|
|
101
|
-
*
|
|
102
|
-
*
|
|
103
|
-
*
|
|
104
|
-
*
|
|
105
|
-
*
|
|
106
|
-
*
|
|
107
|
-
*
|
|
108
|
-
*
|
|
109
|
-
*
|
|
110
|
-
*
|
|
111
|
-
*
|
|
112
|
-
*
|
|
140
|
+
* Protobuf library provides support to pack/unpack Any values in the form
|
|
141
|
+
* of utility functions or additional generated methods of the Any type.
|
|
142
|
+
*
|
|
143
|
+
* Example 1: Pack and unpack a message in C++.
|
|
144
|
+
*
|
|
145
|
+
* Foo foo = ...;
|
|
146
|
+
* Any any;
|
|
147
|
+
* any.PackFrom(foo);
|
|
148
|
+
* ...
|
|
149
|
+
* if (any.UnpackTo(&foo)) {
|
|
150
|
+
* ...
|
|
151
|
+
* }
|
|
152
|
+
*
|
|
153
|
+
* Example 2: Pack and unpack a message in Java.
|
|
154
|
+
*
|
|
155
|
+
* Foo foo = ...;
|
|
156
|
+
* Any any = Any.pack(foo);
|
|
157
|
+
* ...
|
|
158
|
+
* if (any.is(Foo.class)) {
|
|
159
|
+
* foo = any.unpack(Foo.class);
|
|
160
|
+
* }
|
|
161
|
+
* // or ...
|
|
162
|
+
* if (any.isSameTypeAs(Foo.getDefaultInstance())) {
|
|
163
|
+
* foo = any.unpack(Foo.getDefaultInstance());
|
|
164
|
+
* }
|
|
165
|
+
*
|
|
166
|
+
* Example 3: Pack and unpack a message in Python.
|
|
167
|
+
*
|
|
168
|
+
* foo = Foo(...)
|
|
169
|
+
* any = Any()
|
|
170
|
+
* any.Pack(foo)
|
|
171
|
+
* ...
|
|
172
|
+
* if any.Is(Foo.DESCRIPTOR):
|
|
173
|
+
* any.Unpack(foo)
|
|
174
|
+
* ...
|
|
175
|
+
*
|
|
176
|
+
* Example 4: Pack and unpack a message in Go
|
|
177
|
+
*
|
|
178
|
+
* foo := &pb.Foo{...}
|
|
179
|
+
* any, err := anypb.New(foo)
|
|
180
|
+
* if err != nil {
|
|
181
|
+
* ...
|
|
182
|
+
* }
|
|
183
|
+
* ...
|
|
184
|
+
* foo := &pb.Foo{}
|
|
185
|
+
* if err := any.UnmarshalTo(foo); err != nil {
|
|
186
|
+
* ...
|
|
187
|
+
* }
|
|
188
|
+
*
|
|
189
|
+
* The pack methods provided by protobuf library will by default use
|
|
190
|
+
* 'type.googleapis.com/full.type.name' as the type URL and the unpack
|
|
191
|
+
* methods only use the fully qualified type name after the last '/'
|
|
192
|
+
* in the type URL, for example "foo.bar.com/x/y.z" will yield type
|
|
193
|
+
* name "y.z".
|
|
194
|
+
*
|
|
195
|
+
* JSON
|
|
196
|
+
* ====
|
|
197
|
+
* The JSON representation of an `Any` value uses the regular
|
|
198
|
+
* representation of the deserialized, embedded message, with an
|
|
199
|
+
* additional field `@type` which contains the type URL. Example:
|
|
200
|
+
*
|
|
201
|
+
* package google.profile;
|
|
202
|
+
* message Person {
|
|
203
|
+
* string first_name = 1;
|
|
204
|
+
* string last_name = 2;
|
|
205
|
+
* }
|
|
206
|
+
*
|
|
207
|
+
* {
|
|
208
|
+
* "@type": "type.googleapis.com/google.profile.Person",
|
|
209
|
+
* "firstName": <string>,
|
|
210
|
+
* "lastName": <string>
|
|
211
|
+
* }
|
|
212
|
+
*
|
|
213
|
+
* If the embedded message type is well-known and has a custom JSON
|
|
214
|
+
* representation, that representation will be embedded adding a field
|
|
215
|
+
* `value` which holds the custom JSON in addition to the `@type`
|
|
216
|
+
* field. Example (for message [google.protobuf.Duration][]):
|
|
217
|
+
*
|
|
218
|
+
* {
|
|
219
|
+
* "@type": "type.googleapis.com/google.protobuf.Duration",
|
|
220
|
+
* "value": "1.212s"
|
|
221
|
+
* }
|
|
113
222
|
* @name AnyAmino
|
|
114
223
|
* @package google.protobuf
|
|
115
224
|
* @see proto type: google.protobuf.Any
|
|
116
225
|
*/
|
|
117
226
|
interface AnyAmino {
|
|
118
227
|
/**
|
|
119
|
-
*
|
|
120
|
-
*
|
|
121
|
-
*
|
|
122
|
-
*
|
|
228
|
+
* A URL/resource name that uniquely identifies the type of the serialized
|
|
229
|
+
* protocol buffer message. This string must contain at least
|
|
230
|
+
* one "/" character. The last segment of the URL's path must represent
|
|
231
|
+
* the fully qualified name of the type (as in
|
|
232
|
+
* `path/google.protobuf.Duration`). The name should be in a canonical form
|
|
233
|
+
* (e.g., leading "." is not accepted).
|
|
123
234
|
*
|
|
124
|
-
*
|
|
125
|
-
*
|
|
126
|
-
*
|
|
127
|
-
*
|
|
235
|
+
* In practice, teams usually precompile into the binary all types that they
|
|
236
|
+
* expect it to use in the context of Any. However, for URLs which use the
|
|
237
|
+
* scheme `http`, `https`, or no scheme, one can optionally set up a type
|
|
238
|
+
* server that maps type URLs to message definitions as follows:
|
|
128
239
|
*
|
|
129
|
-
*
|
|
130
|
-
*
|
|
131
|
-
*
|
|
132
|
-
*
|
|
133
|
-
*
|
|
134
|
-
*
|
|
240
|
+
* * If no scheme is provided, `https` is assumed.
|
|
241
|
+
* * An HTTP GET on the URL must yield a [google.protobuf.Type][]
|
|
242
|
+
* value in binary format, or produce an error.
|
|
243
|
+
* * Applications are allowed to cache lookup results based on the
|
|
244
|
+
* URL, or have them precompiled into a binary to avoid any
|
|
245
|
+
* lookup. Therefore, binary compatibility needs to be preserved
|
|
246
|
+
* on changes to types. (Use versioned type names to manage
|
|
247
|
+
* breaking changes.)
|
|
135
248
|
*
|
|
136
|
-
*
|
|
137
|
-
*
|
|
138
|
-
*
|
|
139
|
-
*
|
|
140
|
-
* `/-.~_!$&()*+,;=`. Despite our allowing percent encodings, implementations
|
|
141
|
-
* should not unescape them to prevent confusion with existing parsers. For
|
|
142
|
-
* example, `type.googleapis.com%2FFoo` should be rejected.
|
|
249
|
+
* Note: this functionality is not currently available in the official
|
|
250
|
+
* protobuf release, and it is not used for type URLs beginning with
|
|
251
|
+
* type.googleapis.com. As of May 2023, there are no widely used type server
|
|
252
|
+
* implementations and no plans to implement one.
|
|
143
253
|
*
|
|
144
|
-
*
|
|
145
|
-
*
|
|
146
|
-
* implemented one and considers contacting these URLs to be problematic and
|
|
147
|
-
* a potential security issue. Do not attempt to contact type URLs.
|
|
254
|
+
* Schemes other than `http`, `https` (or the empty scheme) might be
|
|
255
|
+
* used with implementation specific semantics.
|
|
148
256
|
*/
|
|
149
257
|
type: string;
|
|
150
258
|
/**
|
|
151
|
-
*
|
|
259
|
+
* Must be a valid serialized protocol buffer of the above specified type.
|
|
152
260
|
*/
|
|
153
261
|
value: any;
|
|
154
262
|
}
|
|
@@ -160,33 +268,88 @@ interface AnyAminoMsg {
|
|
|
160
268
|
* `Any` contains an arbitrary serialized protocol buffer message along with a
|
|
161
269
|
* URL that describes the type of the serialized message.
|
|
162
270
|
*
|
|
163
|
-
*
|
|
164
|
-
*
|
|
165
|
-
*
|
|
166
|
-
*
|
|
167
|
-
*
|
|
168
|
-
*
|
|
169
|
-
*
|
|
170
|
-
*
|
|
171
|
-
*
|
|
172
|
-
*
|
|
173
|
-
*
|
|
174
|
-
*
|
|
175
|
-
*
|
|
176
|
-
*
|
|
177
|
-
*
|
|
178
|
-
*
|
|
179
|
-
*
|
|
180
|
-
*
|
|
181
|
-
*
|
|
182
|
-
*
|
|
183
|
-
*
|
|
184
|
-
*
|
|
185
|
-
*
|
|
186
|
-
*
|
|
187
|
-
*
|
|
188
|
-
*
|
|
189
|
-
*
|
|
271
|
+
* Protobuf library provides support to pack/unpack Any values in the form
|
|
272
|
+
* of utility functions or additional generated methods of the Any type.
|
|
273
|
+
*
|
|
274
|
+
* Example 1: Pack and unpack a message in C++.
|
|
275
|
+
*
|
|
276
|
+
* Foo foo = ...;
|
|
277
|
+
* Any any;
|
|
278
|
+
* any.PackFrom(foo);
|
|
279
|
+
* ...
|
|
280
|
+
* if (any.UnpackTo(&foo)) {
|
|
281
|
+
* ...
|
|
282
|
+
* }
|
|
283
|
+
*
|
|
284
|
+
* Example 2: Pack and unpack a message in Java.
|
|
285
|
+
*
|
|
286
|
+
* Foo foo = ...;
|
|
287
|
+
* Any any = Any.pack(foo);
|
|
288
|
+
* ...
|
|
289
|
+
* if (any.is(Foo.class)) {
|
|
290
|
+
* foo = any.unpack(Foo.class);
|
|
291
|
+
* }
|
|
292
|
+
* // or ...
|
|
293
|
+
* if (any.isSameTypeAs(Foo.getDefaultInstance())) {
|
|
294
|
+
* foo = any.unpack(Foo.getDefaultInstance());
|
|
295
|
+
* }
|
|
296
|
+
*
|
|
297
|
+
* Example 3: Pack and unpack a message in Python.
|
|
298
|
+
*
|
|
299
|
+
* foo = Foo(...)
|
|
300
|
+
* any = Any()
|
|
301
|
+
* any.Pack(foo)
|
|
302
|
+
* ...
|
|
303
|
+
* if any.Is(Foo.DESCRIPTOR):
|
|
304
|
+
* any.Unpack(foo)
|
|
305
|
+
* ...
|
|
306
|
+
*
|
|
307
|
+
* Example 4: Pack and unpack a message in Go
|
|
308
|
+
*
|
|
309
|
+
* foo := &pb.Foo{...}
|
|
310
|
+
* any, err := anypb.New(foo)
|
|
311
|
+
* if err != nil {
|
|
312
|
+
* ...
|
|
313
|
+
* }
|
|
314
|
+
* ...
|
|
315
|
+
* foo := &pb.Foo{}
|
|
316
|
+
* if err := any.UnmarshalTo(foo); err != nil {
|
|
317
|
+
* ...
|
|
318
|
+
* }
|
|
319
|
+
*
|
|
320
|
+
* The pack methods provided by protobuf library will by default use
|
|
321
|
+
* 'type.googleapis.com/full.type.name' as the type URL and the unpack
|
|
322
|
+
* methods only use the fully qualified type name after the last '/'
|
|
323
|
+
* in the type URL, for example "foo.bar.com/x/y.z" will yield type
|
|
324
|
+
* name "y.z".
|
|
325
|
+
*
|
|
326
|
+
* JSON
|
|
327
|
+
* ====
|
|
328
|
+
* The JSON representation of an `Any` value uses the regular
|
|
329
|
+
* representation of the deserialized, embedded message, with an
|
|
330
|
+
* additional field `@type` which contains the type URL. Example:
|
|
331
|
+
*
|
|
332
|
+
* package google.profile;
|
|
333
|
+
* message Person {
|
|
334
|
+
* string first_name = 1;
|
|
335
|
+
* string last_name = 2;
|
|
336
|
+
* }
|
|
337
|
+
*
|
|
338
|
+
* {
|
|
339
|
+
* "@type": "type.googleapis.com/google.profile.Person",
|
|
340
|
+
* "firstName": <string>,
|
|
341
|
+
* "lastName": <string>
|
|
342
|
+
* }
|
|
343
|
+
*
|
|
344
|
+
* If the embedded message type is well-known and has a custom JSON
|
|
345
|
+
* representation, that representation will be embedded adding a field
|
|
346
|
+
* `value` which holds the custom JSON in addition to the `@type`
|
|
347
|
+
* field. Example (for message [google.protobuf.Duration][]):
|
|
348
|
+
*
|
|
349
|
+
* {
|
|
350
|
+
* "@type": "type.googleapis.com/google.protobuf.Duration",
|
|
351
|
+
* "value": "1.212s"
|
|
352
|
+
* }
|
|
190
353
|
* @name Any
|
|
191
354
|
* @package google.protobuf
|
|
192
355
|
* @see proto type: google.protobuf.Any
|
|
@@ -11,33 +11,88 @@ function createBaseAny() {
|
|
|
11
11
|
* `Any` contains an arbitrary serialized protocol buffer message along with a
|
|
12
12
|
* URL that describes the type of the serialized message.
|
|
13
13
|
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
* described on the `type_url` field.
|
|
14
|
+
* Protobuf library provides support to pack/unpack Any values in the form
|
|
15
|
+
* of utility functions or additional generated methods of the Any type.
|
|
17
16
|
*
|
|
18
|
-
*
|
|
17
|
+
* Example 1: Pack and unpack a message in C++.
|
|
19
18
|
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
19
|
+
* Foo foo = ...;
|
|
20
|
+
* Any any;
|
|
21
|
+
* any.PackFrom(foo);
|
|
22
|
+
* ...
|
|
23
|
+
* if (any.UnpackTo(&foo)) {
|
|
24
|
+
* ...
|
|
25
|
+
* }
|
|
27
26
|
*
|
|
28
|
-
*
|
|
27
|
+
* Example 2: Pack and unpack a message in Java.
|
|
29
28
|
*
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
*
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
36
|
-
*
|
|
29
|
+
* Foo foo = ...;
|
|
30
|
+
* Any any = Any.pack(foo);
|
|
31
|
+
* ...
|
|
32
|
+
* if (any.is(Foo.class)) {
|
|
33
|
+
* foo = any.unpack(Foo.class);
|
|
34
|
+
* }
|
|
35
|
+
* // or ...
|
|
36
|
+
* if (any.isSameTypeAs(Foo.getDefaultInstance())) {
|
|
37
|
+
* foo = any.unpack(Foo.getDefaultInstance());
|
|
38
|
+
* }
|
|
37
39
|
*
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
*
|
|
40
|
+
* Example 3: Pack and unpack a message in Python.
|
|
41
|
+
*
|
|
42
|
+
* foo = Foo(...)
|
|
43
|
+
* any = Any()
|
|
44
|
+
* any.Pack(foo)
|
|
45
|
+
* ...
|
|
46
|
+
* if any.Is(Foo.DESCRIPTOR):
|
|
47
|
+
* any.Unpack(foo)
|
|
48
|
+
* ...
|
|
49
|
+
*
|
|
50
|
+
* Example 4: Pack and unpack a message in Go
|
|
51
|
+
*
|
|
52
|
+
* foo := &pb.Foo{...}
|
|
53
|
+
* any, err := anypb.New(foo)
|
|
54
|
+
* if err != nil {
|
|
55
|
+
* ...
|
|
56
|
+
* }
|
|
57
|
+
* ...
|
|
58
|
+
* foo := &pb.Foo{}
|
|
59
|
+
* if err := any.UnmarshalTo(foo); err != nil {
|
|
60
|
+
* ...
|
|
61
|
+
* }
|
|
62
|
+
*
|
|
63
|
+
* The pack methods provided by protobuf library will by default use
|
|
64
|
+
* 'type.googleapis.com/full.type.name' as the type URL and the unpack
|
|
65
|
+
* methods only use the fully qualified type name after the last '/'
|
|
66
|
+
* in the type URL, for example "foo.bar.com/x/y.z" will yield type
|
|
67
|
+
* name "y.z".
|
|
68
|
+
*
|
|
69
|
+
* JSON
|
|
70
|
+
* ====
|
|
71
|
+
* The JSON representation of an `Any` value uses the regular
|
|
72
|
+
* representation of the deserialized, embedded message, with an
|
|
73
|
+
* additional field `@type` which contains the type URL. Example:
|
|
74
|
+
*
|
|
75
|
+
* package google.profile;
|
|
76
|
+
* message Person {
|
|
77
|
+
* string first_name = 1;
|
|
78
|
+
* string last_name = 2;
|
|
79
|
+
* }
|
|
80
|
+
*
|
|
81
|
+
* {
|
|
82
|
+
* "@type": "type.googleapis.com/google.profile.Person",
|
|
83
|
+
* "firstName": <string>,
|
|
84
|
+
* "lastName": <string>
|
|
85
|
+
* }
|
|
86
|
+
*
|
|
87
|
+
* If the embedded message type is well-known and has a custom JSON
|
|
88
|
+
* representation, that representation will be embedded adding a field
|
|
89
|
+
* `value` which holds the custom JSON in addition to the `@type`
|
|
90
|
+
* field. Example (for message [google.protobuf.Duration][]):
|
|
91
|
+
*
|
|
92
|
+
* {
|
|
93
|
+
* "@type": "type.googleapis.com/google.protobuf.Duration",
|
|
94
|
+
* "value": "1.212s"
|
|
95
|
+
* }
|
|
41
96
|
* @name Any
|
|
42
97
|
* @package google.protobuf
|
|
43
98
|
* @see proto type: google.protobuf.Any
|
package/dist/registry.cjs
CHANGED
|
@@ -4,7 +4,7 @@ const require_google_protobuf_any = require('./google/protobuf/any.cjs');
|
|
|
4
4
|
|
|
5
5
|
//#region src/registry.ts
|
|
6
6
|
/**
|
|
7
|
-
* This file and any referenced files were automatically generated by @hyperweb/telescope@
|
|
7
|
+
* This file and any referenced files were automatically generated by @hyperweb/telescope@2.2.4
|
|
8
8
|
* DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
|
|
9
9
|
* and run the transpile command or npm scripts command that is used to regenerate this bundle.
|
|
10
10
|
*/
|
package/dist/registry.d.ts
CHANGED
|
@@ -18,7 +18,7 @@ declare class GlobalDecoderRegistry {
|
|
|
18
18
|
static getDecoderByInstance<T, SDK, Amino>(obj: unknown): TelescopeGeneratedCodec<T, SDK, Amino> | null;
|
|
19
19
|
static getDecoderByAminoType<T, SDK, Amino>(type: string): TelescopeGeneratedCodec<T, SDK, Amino> | null;
|
|
20
20
|
static wrapAny(obj: unknown): Any;
|
|
21
|
-
static unwrapAny<T, SDK, Amino>(input: BinaryReader | Uint8Array | Any):
|
|
21
|
+
static unwrapAny<T, SDK, Amino>(input: BinaryReader | Uint8Array | Any): Any | T;
|
|
22
22
|
static fromJSON<T>(object: any): T;
|
|
23
23
|
static toJSON<T>(message: T): any;
|
|
24
24
|
static fromPartial<T>(object: unknown): T;
|
package/dist/registry.js
CHANGED
|
@@ -3,7 +3,7 @@ import { Any } from "./google/protobuf/any.js";
|
|
|
3
3
|
|
|
4
4
|
//#region src/registry.ts
|
|
5
5
|
/**
|
|
6
|
-
* This file and any referenced files were automatically generated by @hyperweb/telescope@
|
|
6
|
+
* This file and any referenced files were automatically generated by @hyperweb/telescope@2.2.4
|
|
7
7
|
* DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
|
|
8
8
|
* and run the transpile command or npm scripts command that is used to regenerate this bundle.
|
|
9
9
|
*/
|
package/dist/utf8.cjs
CHANGED
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
|
4
4
|
|
|
5
5
|
//#region src/utf8.ts
|
|
6
6
|
/**
|
|
7
|
-
* This file and any referenced files were automatically generated by @hyperweb/telescope@
|
|
7
|
+
* This file and any referenced files were automatically generated by @hyperweb/telescope@2.2.4
|
|
8
8
|
* DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
|
|
9
9
|
* and run the transpile command or npm scripts command that is used to regenerate this bundle.
|
|
10
10
|
*/
|
package/dist/utf8.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
//#region src/utf8.d.ts
|
|
2
2
|
/**
|
|
3
|
-
* This file and any referenced files were automatically generated by @hyperweb/telescope@
|
|
3
|
+
* This file and any referenced files were automatically generated by @hyperweb/telescope@2.2.4
|
|
4
4
|
* DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
|
|
5
5
|
* and run the transpile command or npm scripts command that is used to regenerate this bundle.
|
|
6
6
|
*/
|
package/dist/utf8.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
//#region src/utf8.ts
|
|
2
2
|
/**
|
|
3
|
-
* This file and any referenced files were automatically generated by @hyperweb/telescope@
|
|
3
|
+
* This file and any referenced files were automatically generated by @hyperweb/telescope@2.2.4
|
|
4
4
|
* DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
|
|
5
5
|
* and run the transpile command or npm scripts command that is used to regenerate this bundle.
|
|
6
6
|
*/
|
package/dist/varint.cjs
CHANGED
|
@@ -2,7 +2,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
|
|
|
2
2
|
|
|
3
3
|
//#region src/varint.ts
|
|
4
4
|
/**
|
|
5
|
-
* This file and any referenced files were automatically generated by @hyperweb/telescope@
|
|
5
|
+
* This file and any referenced files were automatically generated by @hyperweb/telescope@2.2.4
|
|
6
6
|
* DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
|
|
7
7
|
* and run the transpile command or npm scripts command that is used to regenerate this bundle.
|
|
8
8
|
*/
|
package/dist/varint.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
//#region src/varint.d.ts
|
|
2
2
|
/**
|
|
3
|
-
* This file and any referenced files were automatically generated by @hyperweb/telescope@
|
|
3
|
+
* This file and any referenced files were automatically generated by @hyperweb/telescope@2.2.4
|
|
4
4
|
* DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
|
|
5
5
|
* and run the transpile command or npm scripts command that is used to regenerate this bundle.
|
|
6
6
|
*/
|
package/dist/varint.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
//#region src/varint.ts
|
|
2
2
|
/**
|
|
3
|
-
* This file and any referenced files were automatically generated by @hyperweb/telescope@
|
|
3
|
+
* This file and any referenced files were automatically generated by @hyperweb/telescope@2.2.4
|
|
4
4
|
* DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
|
|
5
5
|
* and run the transpile command or npm scripts command that is used to regenerate this bundle.
|
|
6
6
|
*/
|
package/dist/xpla/rpc.query.cjs
CHANGED
|
@@ -4,7 +4,7 @@ let _cosmjs_stargate = require("@cosmjs/stargate");
|
|
|
4
4
|
|
|
5
5
|
//#region src/xpla/rpc.query.ts
|
|
6
6
|
const createRPCQueryClient = async ({ rpcEndpoint }) => {
|
|
7
|
-
const client = new _cosmjs_stargate.QueryClient(await _cosmjs_tendermint_rpc.
|
|
7
|
+
const client = new _cosmjs_stargate.QueryClient(await (0, _cosmjs_tendermint_rpc.connectComet)(rpcEndpoint));
|
|
8
8
|
return {
|
|
9
9
|
cosmos: {
|
|
10
10
|
auth: { v1beta1: (await Promise.resolve().then(() => require("../cosmos/auth/v1beta1/query.rpc.Query.cjs"))).createRpcQueryExtension(client) },
|
package/dist/xpla/rpc.query.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { connectComet } from "@cosmjs/tendermint-rpc";
|
|
2
2
|
import { QueryClient } from "@cosmjs/stargate";
|
|
3
3
|
|
|
4
4
|
//#region src/xpla/rpc.query.ts
|
|
5
5
|
const createRPCQueryClient = async ({ rpcEndpoint }) => {
|
|
6
|
-
const client = new QueryClient(await
|
|
6
|
+
const client = new QueryClient(await connectComet(rpcEndpoint));
|
|
7
7
|
return {
|
|
8
8
|
cosmos: {
|
|
9
9
|
auth: { v1beta1: (await import("../cosmos/auth/v1beta1/query.rpc.Query.js")).createRpcQueryExtension(client) },
|
package/package.json
CHANGED
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xpla/xplajs",
|
|
3
|
-
"version": "1.9.
|
|
3
|
+
"version": "1.9.1",
|
|
4
4
|
"main": "dist/index.cjs",
|
|
5
5
|
"module": "dist/index.js",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"author": "Joowon Yun <joowon@delightlabs.io>",
|
|
8
8
|
"homepage": "https://github.com/xpladev/xplajs",
|
|
9
|
+
"scripts": {
|
|
10
|
+
"build": "tsdown",
|
|
11
|
+
"typecheck": "tsc --noEmit"
|
|
12
|
+
},
|
|
9
13
|
"publishConfig": {
|
|
10
14
|
"access": "public"
|
|
11
15
|
},
|
|
@@ -31,26 +35,24 @@
|
|
|
31
35
|
"./package.json": "./package.json"
|
|
32
36
|
},
|
|
33
37
|
"dependencies": {
|
|
34
|
-
"@cosmjs/stargate": "
|
|
35
|
-
"@cosmjs/tendermint-rpc": "
|
|
38
|
+
"@cosmjs/stargate": "catalog:",
|
|
39
|
+
"@cosmjs/tendermint-rpc": "catalog:",
|
|
36
40
|
"@cosmology/lcd": "^0.14.4",
|
|
37
|
-
"@interchainjs/cosmos": "
|
|
38
|
-
"@interchainjs/cosmos-types": "
|
|
39
|
-
"@interchainjs/encoding": "
|
|
40
|
-
"@interchainjs/math": "
|
|
41
|
-
"@interchainjs/pubkey": "
|
|
42
|
-
"@interchainjs/types": "
|
|
43
|
-
"@interchainjs/utils": "
|
|
41
|
+
"@interchainjs/cosmos": "catalog:",
|
|
42
|
+
"@interchainjs/cosmos-types": "catalog:",
|
|
43
|
+
"@interchainjs/encoding": "catalog:",
|
|
44
|
+
"@interchainjs/math": "catalog:",
|
|
45
|
+
"@interchainjs/pubkey": "catalog:",
|
|
46
|
+
"@interchainjs/types": "catalog:",
|
|
47
|
+
"@interchainjs/utils": "catalog:",
|
|
44
48
|
"@noble/hashes": "^1.3.1",
|
|
45
49
|
"decimal.js": "^10.4.3"
|
|
46
50
|
},
|
|
47
51
|
"devDependencies": {
|
|
48
|
-
"@types/node": "
|
|
49
|
-
"tsdown": "
|
|
52
|
+
"@types/node": "catalog:",
|
|
53
|
+
"tsdown": "catalog:"
|
|
50
54
|
},
|
|
51
55
|
"license": "MIT",
|
|
52
56
|
"description": "",
|
|
53
|
-
"
|
|
54
|
-
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
+
"gitHead": "8aec257919fe2b6b89d6dae386bd57b5a3f5d83e"
|
|
58
|
+
}
|