@verana-labs/verana-types 0.10.1-dev.11 → 0.10.1-dev.12
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/codec/google/protobuf/any.d.ts +143 -0
- package/dist/codec/google/protobuf/any.js +139 -0
- package/dist/codec/verana/co/module/v1/module.d.ts +29 -0
- package/dist/codec/verana/co/module/v1/module.js +98 -0
- package/dist/codec/verana/co/v1/genesis.d.ts +28 -0
- package/dist/codec/verana/co/v1/genesis.js +121 -0
- package/dist/codec/verana/co/v1/params.d.ts +29 -0
- package/dist/codec/verana/co/v1/params.js +81 -0
- package/dist/codec/verana/co/v1/query.d.ts +111 -0
- package/dist/codec/verana/co/v1/query.js +484 -0
- package/dist/codec/verana/co/v1/tx.d.ts +172 -0
- package/dist/codec/verana/co/v1/tx.js +639 -0
- package/dist/codec/verana/co/v1/types.d.ts +60 -0
- package/dist/codec/verana/co/v1/types.js +384 -0
- package/dist/codec/verana/gf/module/v1/module.d.ts +29 -0
- package/dist/codec/verana/gf/module/v1/module.js +98 -0
- package/dist/codec/verana/gf/v1/genesis.d.ts +29 -0
- package/dist/codec/verana/gf/v1/genesis.js +137 -0
- package/dist/codec/verana/gf/v1/params.d.ts +28 -0
- package/dist/codec/verana/gf/v1/params.js +81 -0
- package/dist/codec/verana/gf/v1/query.d.ts +108 -0
- package/dist/codec/verana/gf/v1/query.js +462 -0
- package/dist/codec/verana/gf/v1/tx.d.ts +142 -0
- package/dist/codec/verana/gf/v1/tx.js +486 -0
- package/dist/codec/verana/gf/v1/types.d.ts +75 -0
- package/dist/codec/verana/gf/v1/types.js +477 -0
- package/dist/codec/verana/tr/v1/tx.js +2 -2
- package/dist/codec/verana/tr/v1/types.js +8 -8
- package/package.json +1 -1
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
import * as _m0 from "protobufjs/minimal";
|
|
2
|
+
export declare const protobufPackage = "google.protobuf";
|
|
3
|
+
/**
|
|
4
|
+
* `Any` contains an arbitrary serialized protocol buffer message along with a
|
|
5
|
+
* URL that describes the type of the serialized message.
|
|
6
|
+
*
|
|
7
|
+
* Protobuf library provides support to pack/unpack Any values in the form
|
|
8
|
+
* of utility functions or additional generated methods of the Any type.
|
|
9
|
+
*
|
|
10
|
+
* Example 1: Pack and unpack a message in C++.
|
|
11
|
+
*
|
|
12
|
+
* Foo foo = ...;
|
|
13
|
+
* Any any;
|
|
14
|
+
* any.PackFrom(foo);
|
|
15
|
+
* ...
|
|
16
|
+
* if (any.UnpackTo(&foo)) {
|
|
17
|
+
* ...
|
|
18
|
+
* }
|
|
19
|
+
*
|
|
20
|
+
* Example 2: Pack and unpack a message in Java.
|
|
21
|
+
*
|
|
22
|
+
* Foo foo = ...;
|
|
23
|
+
* Any any = Any.pack(foo);
|
|
24
|
+
* ...
|
|
25
|
+
* if (any.is(Foo.class)) {
|
|
26
|
+
* foo = any.unpack(Foo.class);
|
|
27
|
+
* }
|
|
28
|
+
* // or ...
|
|
29
|
+
* if (any.isSameTypeAs(Foo.getDefaultInstance())) {
|
|
30
|
+
* foo = any.unpack(Foo.getDefaultInstance());
|
|
31
|
+
* }
|
|
32
|
+
*
|
|
33
|
+
* Example 3: Pack and unpack a message in Python.
|
|
34
|
+
*
|
|
35
|
+
* foo = Foo(...)
|
|
36
|
+
* any = Any()
|
|
37
|
+
* any.Pack(foo)
|
|
38
|
+
* ...
|
|
39
|
+
* if any.Is(Foo.DESCRIPTOR):
|
|
40
|
+
* any.Unpack(foo)
|
|
41
|
+
* ...
|
|
42
|
+
*
|
|
43
|
+
* Example 4: Pack and unpack a message in Go
|
|
44
|
+
*
|
|
45
|
+
* foo := &pb.Foo{...}
|
|
46
|
+
* any, err := anypb.New(foo)
|
|
47
|
+
* if err != nil {
|
|
48
|
+
* ...
|
|
49
|
+
* }
|
|
50
|
+
* ...
|
|
51
|
+
* foo := &pb.Foo{}
|
|
52
|
+
* if err := any.UnmarshalTo(foo); err != nil {
|
|
53
|
+
* ...
|
|
54
|
+
* }
|
|
55
|
+
*
|
|
56
|
+
* The pack methods provided by protobuf library will by default use
|
|
57
|
+
* 'type.googleapis.com/full.type.name' as the type URL and the unpack
|
|
58
|
+
* methods only use the fully qualified type name after the last '/'
|
|
59
|
+
* in the type URL, for example "foo.bar.com/x/y.z" will yield type
|
|
60
|
+
* name "y.z".
|
|
61
|
+
*
|
|
62
|
+
* JSON
|
|
63
|
+
* ====
|
|
64
|
+
* The JSON representation of an `Any` value uses the regular
|
|
65
|
+
* representation of the deserialized, embedded message, with an
|
|
66
|
+
* additional field `@type` which contains the type URL. Example:
|
|
67
|
+
*
|
|
68
|
+
* package google.profile;
|
|
69
|
+
* message Person {
|
|
70
|
+
* string first_name = 1;
|
|
71
|
+
* string last_name = 2;
|
|
72
|
+
* }
|
|
73
|
+
*
|
|
74
|
+
* {
|
|
75
|
+
* "@type": "type.googleapis.com/google.profile.Person",
|
|
76
|
+
* "firstName": <string>,
|
|
77
|
+
* "lastName": <string>
|
|
78
|
+
* }
|
|
79
|
+
*
|
|
80
|
+
* If the embedded message type is well-known and has a custom JSON
|
|
81
|
+
* representation, that representation will be embedded adding a field
|
|
82
|
+
* `value` which holds the custom JSON in addition to the `@type`
|
|
83
|
+
* field. Example (for message [google.protobuf.Duration][]):
|
|
84
|
+
*
|
|
85
|
+
* {
|
|
86
|
+
* "@type": "type.googleapis.com/google.protobuf.Duration",
|
|
87
|
+
* "value": "1.212s"
|
|
88
|
+
* }
|
|
89
|
+
*/
|
|
90
|
+
export interface Any {
|
|
91
|
+
/**
|
|
92
|
+
* A URL/resource name that uniquely identifies the type of the serialized
|
|
93
|
+
* protocol buffer message. This string must contain at least
|
|
94
|
+
* one "/" character. The last segment of the URL's path must represent
|
|
95
|
+
* the fully qualified name of the type (as in
|
|
96
|
+
* `path/google.protobuf.Duration`). The name should be in a canonical form
|
|
97
|
+
* (e.g., leading "." is not accepted).
|
|
98
|
+
*
|
|
99
|
+
* In practice, teams usually precompile into the binary all types that they
|
|
100
|
+
* expect it to use in the context of Any. However, for URLs which use the
|
|
101
|
+
* scheme `http`, `https`, or no scheme, one can optionally set up a type
|
|
102
|
+
* server that maps type URLs to message definitions as follows:
|
|
103
|
+
*
|
|
104
|
+
* * If no scheme is provided, `https` is assumed.
|
|
105
|
+
* * An HTTP GET on the URL must yield a [google.protobuf.Type][]
|
|
106
|
+
* value in binary format, or produce an error.
|
|
107
|
+
* * Applications are allowed to cache lookup results based on the
|
|
108
|
+
* URL, or have them precompiled into a binary to avoid any
|
|
109
|
+
* lookup. Therefore, binary compatibility needs to be preserved
|
|
110
|
+
* on changes to types. (Use versioned type names to manage
|
|
111
|
+
* breaking changes.)
|
|
112
|
+
*
|
|
113
|
+
* Note: this functionality is not currently available in the official
|
|
114
|
+
* protobuf release, and it is not used for type URLs beginning with
|
|
115
|
+
* type.googleapis.com. As of May 2023, there are no widely used type server
|
|
116
|
+
* implementations and no plans to implement one.
|
|
117
|
+
*
|
|
118
|
+
* Schemes other than `http`, `https` (or the empty scheme) might be
|
|
119
|
+
* used with implementation specific semantics.
|
|
120
|
+
*/
|
|
121
|
+
typeUrl: string;
|
|
122
|
+
/** Must be a valid serialized protocol buffer of the above specified type. */
|
|
123
|
+
value: Uint8Array;
|
|
124
|
+
}
|
|
125
|
+
export declare const Any: {
|
|
126
|
+
encode(message: Any, writer?: _m0.Writer): _m0.Writer;
|
|
127
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): Any;
|
|
128
|
+
fromJSON(object: any): Any;
|
|
129
|
+
toJSON(message: Any): unknown;
|
|
130
|
+
create<I extends Exact<DeepPartial<Any>, I>>(base?: I): Any;
|
|
131
|
+
fromPartial<I extends Exact<DeepPartial<Any>, I>>(object: I): Any;
|
|
132
|
+
};
|
|
133
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
134
|
+
export type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
|
|
135
|
+
[K in keyof T]?: DeepPartial<T[K]>;
|
|
136
|
+
} : Partial<T>;
|
|
137
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
138
|
+
export type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
139
|
+
[K in keyof P]: Exact<P[K], I[K]>;
|
|
140
|
+
} & {
|
|
141
|
+
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
142
|
+
};
|
|
143
|
+
export {};
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v1.181.2
|
|
5
|
+
// protoc unknown
|
|
6
|
+
// source: google/protobuf/any.proto
|
|
7
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
8
|
+
if (k2 === undefined) k2 = k;
|
|
9
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
10
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
11
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
12
|
+
}
|
|
13
|
+
Object.defineProperty(o, k2, desc);
|
|
14
|
+
}) : (function(o, m, k, k2) {
|
|
15
|
+
if (k2 === undefined) k2 = k;
|
|
16
|
+
o[k2] = m[k];
|
|
17
|
+
}));
|
|
18
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
19
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
20
|
+
}) : function(o, v) {
|
|
21
|
+
o["default"] = v;
|
|
22
|
+
});
|
|
23
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
24
|
+
var ownKeys = function(o) {
|
|
25
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
26
|
+
var ar = [];
|
|
27
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
28
|
+
return ar;
|
|
29
|
+
};
|
|
30
|
+
return ownKeys(o);
|
|
31
|
+
};
|
|
32
|
+
return function (mod) {
|
|
33
|
+
if (mod && mod.__esModule) return mod;
|
|
34
|
+
var result = {};
|
|
35
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
36
|
+
__setModuleDefault(result, mod);
|
|
37
|
+
return result;
|
|
38
|
+
};
|
|
39
|
+
})();
|
|
40
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
41
|
+
exports.Any = exports.protobufPackage = void 0;
|
|
42
|
+
/* eslint-disable */
|
|
43
|
+
const _m0 = __importStar(require("protobufjs/minimal"));
|
|
44
|
+
exports.protobufPackage = "google.protobuf";
|
|
45
|
+
function createBaseAny() {
|
|
46
|
+
return { typeUrl: "", value: new Uint8Array(0) };
|
|
47
|
+
}
|
|
48
|
+
exports.Any = {
|
|
49
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
50
|
+
if (message.typeUrl !== "") {
|
|
51
|
+
writer.uint32(10).string(message.typeUrl);
|
|
52
|
+
}
|
|
53
|
+
if (message.value.length !== 0) {
|
|
54
|
+
writer.uint32(18).bytes(message.value);
|
|
55
|
+
}
|
|
56
|
+
return writer;
|
|
57
|
+
},
|
|
58
|
+
decode(input, length) {
|
|
59
|
+
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
60
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
61
|
+
const message = createBaseAny();
|
|
62
|
+
while (reader.pos < end) {
|
|
63
|
+
const tag = reader.uint32();
|
|
64
|
+
switch (tag >>> 3) {
|
|
65
|
+
case 1:
|
|
66
|
+
if (tag !== 10) {
|
|
67
|
+
break;
|
|
68
|
+
}
|
|
69
|
+
message.typeUrl = reader.string();
|
|
70
|
+
continue;
|
|
71
|
+
case 2:
|
|
72
|
+
if (tag !== 18) {
|
|
73
|
+
break;
|
|
74
|
+
}
|
|
75
|
+
message.value = reader.bytes();
|
|
76
|
+
continue;
|
|
77
|
+
}
|
|
78
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
79
|
+
break;
|
|
80
|
+
}
|
|
81
|
+
reader.skipType(tag & 7);
|
|
82
|
+
}
|
|
83
|
+
return message;
|
|
84
|
+
},
|
|
85
|
+
fromJSON(object) {
|
|
86
|
+
return {
|
|
87
|
+
typeUrl: isSet(object.typeUrl) ? globalThis.String(object.typeUrl) : "",
|
|
88
|
+
value: isSet(object.value) ? bytesFromBase64(object.value) : new Uint8Array(0),
|
|
89
|
+
};
|
|
90
|
+
},
|
|
91
|
+
toJSON(message) {
|
|
92
|
+
const obj = {};
|
|
93
|
+
if (message.typeUrl !== "") {
|
|
94
|
+
obj.typeUrl = message.typeUrl;
|
|
95
|
+
}
|
|
96
|
+
if (message.value.length !== 0) {
|
|
97
|
+
obj.value = base64FromBytes(message.value);
|
|
98
|
+
}
|
|
99
|
+
return obj;
|
|
100
|
+
},
|
|
101
|
+
create(base) {
|
|
102
|
+
return exports.Any.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
103
|
+
},
|
|
104
|
+
fromPartial(object) {
|
|
105
|
+
var _a, _b;
|
|
106
|
+
const message = createBaseAny();
|
|
107
|
+
message.typeUrl = (_a = object.typeUrl) !== null && _a !== void 0 ? _a : "";
|
|
108
|
+
message.value = (_b = object.value) !== null && _b !== void 0 ? _b : new Uint8Array(0);
|
|
109
|
+
return message;
|
|
110
|
+
},
|
|
111
|
+
};
|
|
112
|
+
function bytesFromBase64(b64) {
|
|
113
|
+
if (globalThis.Buffer) {
|
|
114
|
+
return Uint8Array.from(globalThis.Buffer.from(b64, "base64"));
|
|
115
|
+
}
|
|
116
|
+
else {
|
|
117
|
+
const bin = globalThis.atob(b64);
|
|
118
|
+
const arr = new Uint8Array(bin.length);
|
|
119
|
+
for (let i = 0; i < bin.length; ++i) {
|
|
120
|
+
arr[i] = bin.charCodeAt(i);
|
|
121
|
+
}
|
|
122
|
+
return arr;
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
function base64FromBytes(arr) {
|
|
126
|
+
if (globalThis.Buffer) {
|
|
127
|
+
return globalThis.Buffer.from(arr).toString("base64");
|
|
128
|
+
}
|
|
129
|
+
else {
|
|
130
|
+
const bin = [];
|
|
131
|
+
arr.forEach((byte) => {
|
|
132
|
+
bin.push(globalThis.String.fromCharCode(byte));
|
|
133
|
+
});
|
|
134
|
+
return globalThis.btoa(bin.join(""));
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
function isSet(value) {
|
|
138
|
+
return value !== null && value !== undefined;
|
|
139
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import * as _m0 from "protobufjs/minimal";
|
|
2
|
+
export declare const protobufPackage = "verana.co.module.v1";
|
|
3
|
+
/** Module is the config object for the module. */
|
|
4
|
+
export interface Module {
|
|
5
|
+
/**
|
|
6
|
+
* authority defines the custom module authority.
|
|
7
|
+
* If not set, defaults to the governance module.
|
|
8
|
+
*/
|
|
9
|
+
authority: string;
|
|
10
|
+
}
|
|
11
|
+
export declare const Module: {
|
|
12
|
+
encode(message: Module, writer?: _m0.Writer): _m0.Writer;
|
|
13
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): Module;
|
|
14
|
+
fromJSON(object: any): Module;
|
|
15
|
+
toJSON(message: Module): unknown;
|
|
16
|
+
create<I extends Exact<DeepPartial<Module>, I>>(base?: I): Module;
|
|
17
|
+
fromPartial<I extends Exact<DeepPartial<Module>, I>>(object: I): Module;
|
|
18
|
+
};
|
|
19
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
20
|
+
export type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
|
|
21
|
+
[K in keyof T]?: DeepPartial<T[K]>;
|
|
22
|
+
} : Partial<T>;
|
|
23
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
24
|
+
export type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
25
|
+
[K in keyof P]: Exact<P[K], I[K]>;
|
|
26
|
+
} & {
|
|
27
|
+
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
28
|
+
};
|
|
29
|
+
export {};
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v1.181.2
|
|
5
|
+
// protoc unknown
|
|
6
|
+
// source: verana/co/module/v1/module.proto
|
|
7
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
8
|
+
if (k2 === undefined) k2 = k;
|
|
9
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
10
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
11
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
12
|
+
}
|
|
13
|
+
Object.defineProperty(o, k2, desc);
|
|
14
|
+
}) : (function(o, m, k, k2) {
|
|
15
|
+
if (k2 === undefined) k2 = k;
|
|
16
|
+
o[k2] = m[k];
|
|
17
|
+
}));
|
|
18
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
19
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
20
|
+
}) : function(o, v) {
|
|
21
|
+
o["default"] = v;
|
|
22
|
+
});
|
|
23
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
24
|
+
var ownKeys = function(o) {
|
|
25
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
26
|
+
var ar = [];
|
|
27
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
28
|
+
return ar;
|
|
29
|
+
};
|
|
30
|
+
return ownKeys(o);
|
|
31
|
+
};
|
|
32
|
+
return function (mod) {
|
|
33
|
+
if (mod && mod.__esModule) return mod;
|
|
34
|
+
var result = {};
|
|
35
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
36
|
+
__setModuleDefault(result, mod);
|
|
37
|
+
return result;
|
|
38
|
+
};
|
|
39
|
+
})();
|
|
40
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
41
|
+
exports.Module = exports.protobufPackage = void 0;
|
|
42
|
+
/* eslint-disable */
|
|
43
|
+
const _m0 = __importStar(require("protobufjs/minimal"));
|
|
44
|
+
exports.protobufPackage = "verana.co.module.v1";
|
|
45
|
+
function createBaseModule() {
|
|
46
|
+
return { authority: "" };
|
|
47
|
+
}
|
|
48
|
+
exports.Module = {
|
|
49
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
50
|
+
if (message.authority !== "") {
|
|
51
|
+
writer.uint32(10).string(message.authority);
|
|
52
|
+
}
|
|
53
|
+
return writer;
|
|
54
|
+
},
|
|
55
|
+
decode(input, length) {
|
|
56
|
+
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
57
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
58
|
+
const message = createBaseModule();
|
|
59
|
+
while (reader.pos < end) {
|
|
60
|
+
const tag = reader.uint32();
|
|
61
|
+
switch (tag >>> 3) {
|
|
62
|
+
case 1:
|
|
63
|
+
if (tag !== 10) {
|
|
64
|
+
break;
|
|
65
|
+
}
|
|
66
|
+
message.authority = reader.string();
|
|
67
|
+
continue;
|
|
68
|
+
}
|
|
69
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
70
|
+
break;
|
|
71
|
+
}
|
|
72
|
+
reader.skipType(tag & 7);
|
|
73
|
+
}
|
|
74
|
+
return message;
|
|
75
|
+
},
|
|
76
|
+
fromJSON(object) {
|
|
77
|
+
return { authority: isSet(object.authority) ? globalThis.String(object.authority) : "" };
|
|
78
|
+
},
|
|
79
|
+
toJSON(message) {
|
|
80
|
+
const obj = {};
|
|
81
|
+
if (message.authority !== "") {
|
|
82
|
+
obj.authority = message.authority;
|
|
83
|
+
}
|
|
84
|
+
return obj;
|
|
85
|
+
},
|
|
86
|
+
create(base) {
|
|
87
|
+
return exports.Module.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
88
|
+
},
|
|
89
|
+
fromPartial(object) {
|
|
90
|
+
var _a;
|
|
91
|
+
const message = createBaseModule();
|
|
92
|
+
message.authority = (_a = object.authority) !== null && _a !== void 0 ? _a : "";
|
|
93
|
+
return message;
|
|
94
|
+
},
|
|
95
|
+
};
|
|
96
|
+
function isSet(value) {
|
|
97
|
+
return value !== null && value !== undefined;
|
|
98
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as _m0 from "protobufjs/minimal";
|
|
2
|
+
import { Params } from "./params";
|
|
3
|
+
import { Corporation } from "./types";
|
|
4
|
+
export declare const protobufPackage = "verana.co.v1";
|
|
5
|
+
/** GenesisState defines the co module's genesis state. */
|
|
6
|
+
export interface GenesisState {
|
|
7
|
+
params: Params | undefined;
|
|
8
|
+
corporations: Corporation[];
|
|
9
|
+
}
|
|
10
|
+
export declare const GenesisState: {
|
|
11
|
+
encode(message: GenesisState, writer?: _m0.Writer): _m0.Writer;
|
|
12
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): GenesisState;
|
|
13
|
+
fromJSON(object: any): GenesisState;
|
|
14
|
+
toJSON(message: GenesisState): unknown;
|
|
15
|
+
create<I extends Exact<DeepPartial<GenesisState>, I>>(base?: I): GenesisState;
|
|
16
|
+
fromPartial<I extends Exact<DeepPartial<GenesisState>, I>>(object: I): GenesisState;
|
|
17
|
+
};
|
|
18
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
19
|
+
export type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
|
|
20
|
+
[K in keyof T]?: DeepPartial<T[K]>;
|
|
21
|
+
} : Partial<T>;
|
|
22
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
23
|
+
export type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
24
|
+
[K in keyof P]: Exact<P[K], I[K]>;
|
|
25
|
+
} & {
|
|
26
|
+
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
27
|
+
};
|
|
28
|
+
export {};
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v1.181.2
|
|
5
|
+
// protoc unknown
|
|
6
|
+
// source: verana/co/v1/genesis.proto
|
|
7
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
8
|
+
if (k2 === undefined) k2 = k;
|
|
9
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
10
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
11
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
12
|
+
}
|
|
13
|
+
Object.defineProperty(o, k2, desc);
|
|
14
|
+
}) : (function(o, m, k, k2) {
|
|
15
|
+
if (k2 === undefined) k2 = k;
|
|
16
|
+
o[k2] = m[k];
|
|
17
|
+
}));
|
|
18
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
19
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
20
|
+
}) : function(o, v) {
|
|
21
|
+
o["default"] = v;
|
|
22
|
+
});
|
|
23
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
24
|
+
var ownKeys = function(o) {
|
|
25
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
26
|
+
var ar = [];
|
|
27
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
28
|
+
return ar;
|
|
29
|
+
};
|
|
30
|
+
return ownKeys(o);
|
|
31
|
+
};
|
|
32
|
+
return function (mod) {
|
|
33
|
+
if (mod && mod.__esModule) return mod;
|
|
34
|
+
var result = {};
|
|
35
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
36
|
+
__setModuleDefault(result, mod);
|
|
37
|
+
return result;
|
|
38
|
+
};
|
|
39
|
+
})();
|
|
40
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
41
|
+
exports.GenesisState = exports.protobufPackage = void 0;
|
|
42
|
+
/* eslint-disable */
|
|
43
|
+
const _m0 = __importStar(require("protobufjs/minimal"));
|
|
44
|
+
const params_1 = require("./params");
|
|
45
|
+
const types_1 = require("./types");
|
|
46
|
+
exports.protobufPackage = "verana.co.v1";
|
|
47
|
+
function createBaseGenesisState() {
|
|
48
|
+
return { params: undefined, corporations: [] };
|
|
49
|
+
}
|
|
50
|
+
exports.GenesisState = {
|
|
51
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
52
|
+
if (message.params !== undefined) {
|
|
53
|
+
params_1.Params.encode(message.params, writer.uint32(10).fork()).ldelim();
|
|
54
|
+
}
|
|
55
|
+
for (const v of message.corporations) {
|
|
56
|
+
types_1.Corporation.encode(v, writer.uint32(18).fork()).ldelim();
|
|
57
|
+
}
|
|
58
|
+
return writer;
|
|
59
|
+
},
|
|
60
|
+
decode(input, length) {
|
|
61
|
+
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
62
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
63
|
+
const message = createBaseGenesisState();
|
|
64
|
+
while (reader.pos < end) {
|
|
65
|
+
const tag = reader.uint32();
|
|
66
|
+
switch (tag >>> 3) {
|
|
67
|
+
case 1:
|
|
68
|
+
if (tag !== 10) {
|
|
69
|
+
break;
|
|
70
|
+
}
|
|
71
|
+
message.params = params_1.Params.decode(reader, reader.uint32());
|
|
72
|
+
continue;
|
|
73
|
+
case 2:
|
|
74
|
+
if (tag !== 18) {
|
|
75
|
+
break;
|
|
76
|
+
}
|
|
77
|
+
message.corporations.push(types_1.Corporation.decode(reader, reader.uint32()));
|
|
78
|
+
continue;
|
|
79
|
+
}
|
|
80
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
81
|
+
break;
|
|
82
|
+
}
|
|
83
|
+
reader.skipType(tag & 7);
|
|
84
|
+
}
|
|
85
|
+
return message;
|
|
86
|
+
},
|
|
87
|
+
fromJSON(object) {
|
|
88
|
+
return {
|
|
89
|
+
params: isSet(object.params) ? params_1.Params.fromJSON(object.params) : undefined,
|
|
90
|
+
corporations: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.corporations)
|
|
91
|
+
? object.corporations.map((e) => types_1.Corporation.fromJSON(e))
|
|
92
|
+
: [],
|
|
93
|
+
};
|
|
94
|
+
},
|
|
95
|
+
toJSON(message) {
|
|
96
|
+
var _a;
|
|
97
|
+
const obj = {};
|
|
98
|
+
if (message.params !== undefined) {
|
|
99
|
+
obj.params = params_1.Params.toJSON(message.params);
|
|
100
|
+
}
|
|
101
|
+
if ((_a = message.corporations) === null || _a === void 0 ? void 0 : _a.length) {
|
|
102
|
+
obj.corporations = message.corporations.map((e) => types_1.Corporation.toJSON(e));
|
|
103
|
+
}
|
|
104
|
+
return obj;
|
|
105
|
+
},
|
|
106
|
+
create(base) {
|
|
107
|
+
return exports.GenesisState.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
108
|
+
},
|
|
109
|
+
fromPartial(object) {
|
|
110
|
+
var _a;
|
|
111
|
+
const message = createBaseGenesisState();
|
|
112
|
+
message.params = (object.params !== undefined && object.params !== null)
|
|
113
|
+
? params_1.Params.fromPartial(object.params)
|
|
114
|
+
: undefined;
|
|
115
|
+
message.corporations = ((_a = object.corporations) === null || _a === void 0 ? void 0 : _a.map((e) => types_1.Corporation.fromPartial(e))) || [];
|
|
116
|
+
return message;
|
|
117
|
+
},
|
|
118
|
+
};
|
|
119
|
+
function isSet(value) {
|
|
120
|
+
return value !== null && value !== undefined;
|
|
121
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import * as _m0 from "protobufjs/minimal";
|
|
2
|
+
export declare const protobufPackage = "verana.co.v1";
|
|
3
|
+
/**
|
|
4
|
+
* Params defines the parameters for the x/co module.
|
|
5
|
+
* The module has no parameters at this time; the message is kept for forward
|
|
6
|
+
* compatibility so that gov-proposed parameter changes can land without proto
|
|
7
|
+
* migrations.
|
|
8
|
+
*/
|
|
9
|
+
export interface Params {
|
|
10
|
+
}
|
|
11
|
+
export declare const Params: {
|
|
12
|
+
encode(_: Params, writer?: _m0.Writer): _m0.Writer;
|
|
13
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): Params;
|
|
14
|
+
fromJSON(_: any): Params;
|
|
15
|
+
toJSON(_: Params): unknown;
|
|
16
|
+
create<I extends Exact<DeepPartial<Params>, I>>(base?: I): Params;
|
|
17
|
+
fromPartial<I extends Exact<DeepPartial<Params>, I>>(_: I): Params;
|
|
18
|
+
};
|
|
19
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
20
|
+
export type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
|
|
21
|
+
[K in keyof T]?: DeepPartial<T[K]>;
|
|
22
|
+
} : Partial<T>;
|
|
23
|
+
type KeysOfUnion<T> = T extends T ? keyof T : never;
|
|
24
|
+
export type Exact<P, I extends P> = P extends Builtin ? P : P & {
|
|
25
|
+
[K in keyof P]: Exact<P[K], I[K]>;
|
|
26
|
+
} & {
|
|
27
|
+
[K in Exclude<keyof I, KeysOfUnion<P>>]: never;
|
|
28
|
+
};
|
|
29
|
+
export {};
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
3
|
+
// versions:
|
|
4
|
+
// protoc-gen-ts_proto v1.181.2
|
|
5
|
+
// protoc unknown
|
|
6
|
+
// source: verana/co/v1/params.proto
|
|
7
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
8
|
+
if (k2 === undefined) k2 = k;
|
|
9
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
10
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
11
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
12
|
+
}
|
|
13
|
+
Object.defineProperty(o, k2, desc);
|
|
14
|
+
}) : (function(o, m, k, k2) {
|
|
15
|
+
if (k2 === undefined) k2 = k;
|
|
16
|
+
o[k2] = m[k];
|
|
17
|
+
}));
|
|
18
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
19
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
20
|
+
}) : function(o, v) {
|
|
21
|
+
o["default"] = v;
|
|
22
|
+
});
|
|
23
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
24
|
+
var ownKeys = function(o) {
|
|
25
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
26
|
+
var ar = [];
|
|
27
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
28
|
+
return ar;
|
|
29
|
+
};
|
|
30
|
+
return ownKeys(o);
|
|
31
|
+
};
|
|
32
|
+
return function (mod) {
|
|
33
|
+
if (mod && mod.__esModule) return mod;
|
|
34
|
+
var result = {};
|
|
35
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
36
|
+
__setModuleDefault(result, mod);
|
|
37
|
+
return result;
|
|
38
|
+
};
|
|
39
|
+
})();
|
|
40
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
41
|
+
exports.Params = exports.protobufPackage = void 0;
|
|
42
|
+
/* eslint-disable */
|
|
43
|
+
const _m0 = __importStar(require("protobufjs/minimal"));
|
|
44
|
+
exports.protobufPackage = "verana.co.v1";
|
|
45
|
+
function createBaseParams() {
|
|
46
|
+
return {};
|
|
47
|
+
}
|
|
48
|
+
exports.Params = {
|
|
49
|
+
encode(_, writer = _m0.Writer.create()) {
|
|
50
|
+
return writer;
|
|
51
|
+
},
|
|
52
|
+
decode(input, length) {
|
|
53
|
+
const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
|
|
54
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
55
|
+
const message = createBaseParams();
|
|
56
|
+
while (reader.pos < end) {
|
|
57
|
+
const tag = reader.uint32();
|
|
58
|
+
switch (tag >>> 3) {
|
|
59
|
+
}
|
|
60
|
+
if ((tag & 7) === 4 || tag === 0) {
|
|
61
|
+
break;
|
|
62
|
+
}
|
|
63
|
+
reader.skipType(tag & 7);
|
|
64
|
+
}
|
|
65
|
+
return message;
|
|
66
|
+
},
|
|
67
|
+
fromJSON(_) {
|
|
68
|
+
return {};
|
|
69
|
+
},
|
|
70
|
+
toJSON(_) {
|
|
71
|
+
const obj = {};
|
|
72
|
+
return obj;
|
|
73
|
+
},
|
|
74
|
+
create(base) {
|
|
75
|
+
return exports.Params.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
76
|
+
},
|
|
77
|
+
fromPartial(_) {
|
|
78
|
+
const message = createBaseParams();
|
|
79
|
+
return message;
|
|
80
|
+
},
|
|
81
|
+
};
|