@verana-labs/verana-types 0.10.1-dev.6 → 0.10.1-dev.8
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/amino-converter/cs.d.ts +4 -0
- package/dist/amino-converter/cs.js +96 -0
- package/dist/amino-converter/de.d.ts +3 -0
- package/dist/amino-converter/de.js +51 -0
- package/dist/amino-converter/di.d.ts +2 -0
- package/dist/amino-converter/di.js +21 -0
- package/dist/amino-converter/perm.d.ts +12 -0
- package/dist/amino-converter/perm.js +307 -0
- package/dist/amino-converter/td.d.ts +5 -0
- package/dist/amino-converter/td.js +52 -0
- package/dist/amino-converter/tr.d.ts +6 -0
- package/dist/amino-converter/tr.js +91 -0
- package/dist/amino-converter/util/helpers.d.ts +30 -0
- package/dist/amino-converter/util/helpers.js +88 -0
- package/dist/amino-converter/xr.d.ts +4 -0
- package/dist/amino-converter/xr.js +68 -0
- package/dist/codec/cosmos/base/v1beta1/coin.d.ts +1 -1
- package/dist/codec/google/protobuf/descriptor.d.ts +5 -0
- package/dist/codec/google/protobuf/descriptor.js +16 -2
- package/dist/codec/google/protobuf/timestamp.d.ts +3 -3
- package/dist/codec/verana/de/v1/genesis.d.ts +7 -0
- package/dist/codec/verana/de/v1/genesis.js +57 -2
- package/dist/codec/verana/de/v1/query.d.ts +39 -1
- package/dist/codec/verana/de/v1/query.js +145 -1
- package/dist/codec/verana/{dd/module → di/module/v1}/module.d.ts +5 -2
- package/dist/codec/verana/{dd/module → di/module/v1}/module.js +2 -2
- package/dist/codec/verana/{dd → di}/v1/genesis.d.ts +5 -4
- package/dist/codec/verana/{dd → di}/v1/genesis.js +11 -13
- package/dist/codec/verana/{dd → di}/v1/params.d.ts +5 -7
- package/dist/codec/verana/di/v1/params.js +81 -0
- package/dist/codec/verana/di/v1/query.d.ts +99 -0
- package/dist/codec/verana/{dd → di}/v1/query.js +65 -166
- package/dist/codec/verana/di/v1/tx.d.ts +116 -0
- package/dist/codec/verana/di/v1/tx.js +381 -0
- package/dist/codec/verana/td/v1/genesis.d.ts +2 -0
- package/dist/codec/verana/td/v1/genesis.js +16 -2
- package/dist/codec/verana/xr/module/v1/module.d.ts +29 -0
- package/dist/codec/verana/xr/module/v1/module.js +98 -0
- package/dist/codec/verana/xr/v1/genesis.d.ts +32 -0
- package/dist/codec/verana/{dd/v1/params.js → xr/v1/genesis.js} +46 -29
- package/dist/codec/verana/xr/v1/params.d.ts +24 -0
- package/dist/codec/verana/xr/v1/params.js +81 -0
- package/dist/codec/verana/xr/v1/query.d.ts +162 -0
- package/dist/codec/verana/xr/v1/query.js +775 -0
- package/dist/codec/verana/xr/v1/tx.d.ts +190 -0
- package/dist/codec/verana/xr/v1/tx.js +894 -0
- package/dist/helpers/aminoConverters.d.ts +8 -36
- package/dist/helpers/aminoConverters.js +21 -703
- package/dist/index.d.ts +9 -1
- package/dist/index.js +9 -1
- package/dist/signing.d.ts +67 -0
- package/dist/signing.js +124 -0
- package/package.json +31 -5
- package/dist/codec/verana/dd/v1/query.d.ts +0 -108
- package/dist/codec/verana/dd/v1/tx.d.ts +0 -173
- package/dist/codec/verana/dd/v1/tx.js +0 -636
- package/dist/codec/verana/dd/v1/types.d.ts +0 -30
- package/dist/codec/verana/dd/v1/types.js +0 -206
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.MsgIncreaseActiveGovernanceFrameworkVersionAminoConverter = exports.MsgAddGovernanceFrameworkDocumentAminoConverter = exports.MsgArchiveTrustRegistryAminoConverter = exports.MsgUpdateTrustRegistryAminoConverter = exports.MsgCreateTrustRegistryAminoConverter = void 0;
|
|
4
|
+
const tx_1 = require("../codec/verana/tr/v1/tx");
|
|
5
|
+
exports.MsgCreateTrustRegistryAminoConverter = {
|
|
6
|
+
aminoType: "/verana.tr.v1.MsgCreateTrustRegistry",
|
|
7
|
+
toAmino: ({ authority, operator, did, aka, language, docUrl, docDigestSri }) => ({
|
|
8
|
+
authority,
|
|
9
|
+
operator,
|
|
10
|
+
did,
|
|
11
|
+
aka,
|
|
12
|
+
language,
|
|
13
|
+
doc_url: docUrl,
|
|
14
|
+
doc_digest_sri: docDigestSri,
|
|
15
|
+
}),
|
|
16
|
+
fromAmino: (value) => tx_1.MsgCreateTrustRegistry.fromPartial({
|
|
17
|
+
authority: value.authority,
|
|
18
|
+
operator: value.operator,
|
|
19
|
+
did: value.did,
|
|
20
|
+
aka: value.aka,
|
|
21
|
+
language: value.language,
|
|
22
|
+
docUrl: value.doc_url,
|
|
23
|
+
docDigestSri: value.doc_digest_sri,
|
|
24
|
+
}),
|
|
25
|
+
};
|
|
26
|
+
exports.MsgUpdateTrustRegistryAminoConverter = {
|
|
27
|
+
aminoType: "/verana.tr.v1.MsgUpdateTrustRegistry",
|
|
28
|
+
toAmino: ({ authority, operator, id, did, aka }) => ({
|
|
29
|
+
authority,
|
|
30
|
+
operator,
|
|
31
|
+
id: id != null ? id.toString() : undefined,
|
|
32
|
+
did,
|
|
33
|
+
aka,
|
|
34
|
+
}),
|
|
35
|
+
fromAmino: (value) => tx_1.MsgUpdateTrustRegistry.fromPartial({
|
|
36
|
+
authority: value.authority,
|
|
37
|
+
operator: value.operator,
|
|
38
|
+
id: value.id != null ? Number(value.id) : 0,
|
|
39
|
+
did: value.did,
|
|
40
|
+
aka: value.aka,
|
|
41
|
+
}),
|
|
42
|
+
};
|
|
43
|
+
exports.MsgArchiveTrustRegistryAminoConverter = {
|
|
44
|
+
aminoType: "/verana.tr.v1.MsgArchiveTrustRegistry",
|
|
45
|
+
toAmino: ({ authority, operator, id, archive }) => ({
|
|
46
|
+
authority,
|
|
47
|
+
operator,
|
|
48
|
+
id: id != null ? id.toString() : undefined,
|
|
49
|
+
archive,
|
|
50
|
+
}),
|
|
51
|
+
fromAmino: (value) => tx_1.MsgArchiveTrustRegistry.fromPartial({
|
|
52
|
+
authority: value.authority,
|
|
53
|
+
operator: value.operator,
|
|
54
|
+
id: value.id != null ? Number(value.id) : 0,
|
|
55
|
+
archive: value.archive,
|
|
56
|
+
}),
|
|
57
|
+
};
|
|
58
|
+
exports.MsgAddGovernanceFrameworkDocumentAminoConverter = {
|
|
59
|
+
aminoType: "/verana.tr.v1.MsgAddGovernanceFrameworkDocument",
|
|
60
|
+
toAmino: ({ authority, operator, id, docLanguage, docUrl, docDigestSri, version, }) => ({
|
|
61
|
+
authority,
|
|
62
|
+
operator,
|
|
63
|
+
id: id != null ? id.toString() : undefined,
|
|
64
|
+
doc_language: docLanguage,
|
|
65
|
+
doc_url: docUrl,
|
|
66
|
+
doc_digest_sri: docDigestSri,
|
|
67
|
+
version,
|
|
68
|
+
}),
|
|
69
|
+
fromAmino: (value) => tx_1.MsgAddGovernanceFrameworkDocument.fromPartial({
|
|
70
|
+
authority: value.authority,
|
|
71
|
+
operator: value.operator,
|
|
72
|
+
id: value.id != null ? Number(value.id) : 0,
|
|
73
|
+
docLanguage: value.doc_language,
|
|
74
|
+
docUrl: value.doc_url,
|
|
75
|
+
docDigestSri: value.doc_digest_sri,
|
|
76
|
+
version: value.version,
|
|
77
|
+
}),
|
|
78
|
+
};
|
|
79
|
+
exports.MsgIncreaseActiveGovernanceFrameworkVersionAminoConverter = {
|
|
80
|
+
aminoType: "/verana.tr.v1.MsgIncreaseActiveGovernanceFrameworkVersion",
|
|
81
|
+
toAmino: ({ authority, operator, id }) => ({
|
|
82
|
+
authority,
|
|
83
|
+
operator,
|
|
84
|
+
id: id != null ? id.toString() : undefined,
|
|
85
|
+
}),
|
|
86
|
+
fromAmino: (value) => tx_1.MsgIncreaseActiveGovernanceFrameworkVersion.fromPartial({
|
|
87
|
+
authority: value.authority,
|
|
88
|
+
operator: value.operator,
|
|
89
|
+
id: value.id != null ? Number(value.id) : 0,
|
|
90
|
+
}),
|
|
91
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import Long from "long";
|
|
2
|
+
import type { Duration } from "../../codec/google/protobuf/duration";
|
|
3
|
+
import type { OptionalUInt32 } from "../../codec/verana/cs/v1/tx";
|
|
4
|
+
export declare const clean: <T extends Record<string, any>>(o: T) => T;
|
|
5
|
+
export declare const u64ToStr: (v?: Long | string | number | null) => string | undefined;
|
|
6
|
+
export declare const u64ToStrIfNonZero: (v?: Long | string | number | null) => string | undefined;
|
|
7
|
+
export declare const strToU64: (s?: string | null) => Long | undefined;
|
|
8
|
+
export declare const u32ToAmino: (n?: number | null) => number | undefined;
|
|
9
|
+
export declare const pickOptionalUInt32: (v: any) => OptionalUInt32 | undefined;
|
|
10
|
+
export declare const pickU32: (v: any) => OptionalUInt32 | undefined;
|
|
11
|
+
export declare const toOptU32Amino: (m?: {
|
|
12
|
+
value: number;
|
|
13
|
+
} | undefined) => {
|
|
14
|
+
value?: undefined;
|
|
15
|
+
} | {
|
|
16
|
+
value: number;
|
|
17
|
+
} | undefined;
|
|
18
|
+
export declare const fromOptU32Amino: (x: any) => OptionalUInt32 | undefined;
|
|
19
|
+
export declare const dateToIsoAmino: (d?: Date | null) => string | undefined;
|
|
20
|
+
export declare const isoToDate: (s?: string | null) => Date | undefined;
|
|
21
|
+
export declare const dateToAmino: (d?: Date | null) => string | undefined;
|
|
22
|
+
export declare const dateFromAmino: (s?: string | null) => Date | undefined;
|
|
23
|
+
export declare const durationToAmino: (d?: Duration | null) => {
|
|
24
|
+
seconds: string;
|
|
25
|
+
nanos: number | undefined;
|
|
26
|
+
} | undefined;
|
|
27
|
+
export declare const aminoToDuration: (d?: {
|
|
28
|
+
seconds?: string | number | null;
|
|
29
|
+
nanos?: string | number | null;
|
|
30
|
+
} | null) => Duration | undefined;
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.aminoToDuration = exports.durationToAmino = exports.dateFromAmino = exports.dateToAmino = exports.isoToDate = exports.dateToIsoAmino = exports.fromOptU32Amino = exports.toOptU32Amino = exports.pickU32 = exports.pickOptionalUInt32 = exports.u32ToAmino = exports.strToU64 = exports.u64ToStrIfNonZero = exports.u64ToStr = exports.clean = void 0;
|
|
7
|
+
const long_1 = __importDefault(require("long"));
|
|
8
|
+
const clean = (o) => {
|
|
9
|
+
Object.keys(o).forEach((k) => o[k] === undefined && delete o[k]);
|
|
10
|
+
return o;
|
|
11
|
+
};
|
|
12
|
+
exports.clean = clean;
|
|
13
|
+
const u64ToStr = (v) => v != null ? long_1.default.fromValue(v).toString() : undefined;
|
|
14
|
+
exports.u64ToStr = u64ToStr;
|
|
15
|
+
const u64ToStrIfNonZero = (v) => {
|
|
16
|
+
if (v == null)
|
|
17
|
+
return undefined;
|
|
18
|
+
const value = long_1.default.fromValue(v);
|
|
19
|
+
return value.isZero() ? undefined : value.toString();
|
|
20
|
+
};
|
|
21
|
+
exports.u64ToStrIfNonZero = u64ToStrIfNonZero;
|
|
22
|
+
const strToU64 = (s) => s != null ? long_1.default.fromString(s) : undefined;
|
|
23
|
+
exports.strToU64 = strToU64;
|
|
24
|
+
const u32ToAmino = (n) => n == null ? undefined : (((n >>> 0) === 0) ? 0 : (n >>> 0));
|
|
25
|
+
exports.u32ToAmino = u32ToAmino;
|
|
26
|
+
const pickOptionalUInt32 = (v) => {
|
|
27
|
+
if (v === undefined || v === null)
|
|
28
|
+
return undefined;
|
|
29
|
+
if (typeof v === "string" && v.trim() === "")
|
|
30
|
+
return undefined;
|
|
31
|
+
const n = Number(v);
|
|
32
|
+
if (!Number.isFinite(n))
|
|
33
|
+
return undefined;
|
|
34
|
+
return { value: n >>> 0 };
|
|
35
|
+
};
|
|
36
|
+
exports.pickOptionalUInt32 = pickOptionalUInt32;
|
|
37
|
+
exports.pickU32 = exports.pickOptionalUInt32;
|
|
38
|
+
const toOptU32Amino = (m) => {
|
|
39
|
+
if (!m)
|
|
40
|
+
return undefined;
|
|
41
|
+
const value = Number(m.value) >>> 0;
|
|
42
|
+
return value === 0 ? {} : { value };
|
|
43
|
+
};
|
|
44
|
+
exports.toOptU32Amino = toOptU32Amino;
|
|
45
|
+
const fromOptU32Amino = (x) => {
|
|
46
|
+
if (x == null)
|
|
47
|
+
return undefined;
|
|
48
|
+
if (typeof x === "object" && x.value == null)
|
|
49
|
+
return { value: 0 };
|
|
50
|
+
const n = typeof x === "object" ? x.value : x;
|
|
51
|
+
if (n === undefined || n === null)
|
|
52
|
+
return undefined;
|
|
53
|
+
if (typeof n === "string" && n.trim() === "")
|
|
54
|
+
return undefined;
|
|
55
|
+
return { value: Number(n) >>> 0 };
|
|
56
|
+
};
|
|
57
|
+
exports.fromOptU32Amino = fromOptU32Amino;
|
|
58
|
+
const dateToIsoAmino = (d) => {
|
|
59
|
+
if (d == null)
|
|
60
|
+
return undefined;
|
|
61
|
+
return d
|
|
62
|
+
.toISOString()
|
|
63
|
+
.replace(/\.000Z$/, "Z")
|
|
64
|
+
.replace(/(\.\d*?[1-9])0+Z$/, "$1Z");
|
|
65
|
+
};
|
|
66
|
+
exports.dateToIsoAmino = dateToIsoAmino;
|
|
67
|
+
const isoToDate = (s) => s != null ? new Date(s) : undefined;
|
|
68
|
+
exports.isoToDate = isoToDate;
|
|
69
|
+
exports.dateToAmino = exports.dateToIsoAmino;
|
|
70
|
+
exports.dateFromAmino = exports.isoToDate;
|
|
71
|
+
const durationToAmino = (d) => {
|
|
72
|
+
if (!d)
|
|
73
|
+
return undefined;
|
|
74
|
+
return (0, exports.clean)({
|
|
75
|
+
seconds: long_1.default.fromValue(d.seconds).toString(),
|
|
76
|
+
nanos: d.nanos === 0 ? undefined : d.nanos,
|
|
77
|
+
});
|
|
78
|
+
};
|
|
79
|
+
exports.durationToAmino = durationToAmino;
|
|
80
|
+
const aminoToDuration = (d) => {
|
|
81
|
+
if (!d)
|
|
82
|
+
return undefined;
|
|
83
|
+
return {
|
|
84
|
+
seconds: d.seconds == null ? 0 : Number(d.seconds),
|
|
85
|
+
nanos: d.nanos == null ? 0 : Number(d.nanos),
|
|
86
|
+
};
|
|
87
|
+
};
|
|
88
|
+
exports.aminoToDuration = aminoToDuration;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { AminoConverter } from "@cosmjs/stargate";
|
|
2
|
+
export declare const MsgCreateExchangeRateAminoConverter: AminoConverter;
|
|
3
|
+
export declare const MsgUpdateExchangeRateAminoConverter: AminoConverter;
|
|
4
|
+
export declare const MsgToggleExchangeRateStateAminoConverter: AminoConverter;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.MsgToggleExchangeRateStateAminoConverter = exports.MsgUpdateExchangeRateAminoConverter = exports.MsgCreateExchangeRateAminoConverter = void 0;
|
|
4
|
+
const tx_1 = require("../codec/verana/xr/v1/tx");
|
|
5
|
+
const helpers_1 = require("./util/helpers");
|
|
6
|
+
exports.MsgCreateExchangeRateAminoConverter = {
|
|
7
|
+
aminoType: "/verana.xr.v1.MsgCreateExchangeRate",
|
|
8
|
+
toAmino: (m) => {
|
|
9
|
+
var _a, _b;
|
|
10
|
+
return (0, helpers_1.clean)({
|
|
11
|
+
authority: m.authority || undefined,
|
|
12
|
+
base_asset_type: (_a = m.baseAssetType) !== null && _a !== void 0 ? _a : 0,
|
|
13
|
+
base_asset: m.baseAsset || undefined,
|
|
14
|
+
quote_asset_type: (_b = m.quoteAssetType) !== null && _b !== void 0 ? _b : 0,
|
|
15
|
+
quote_asset: m.quoteAsset || undefined,
|
|
16
|
+
rate: m.rate || undefined,
|
|
17
|
+
rate_scale: (0, helpers_1.u32ToAmino)(m.rateScale),
|
|
18
|
+
validity_duration: (0, helpers_1.durationToAmino)(m.validityDuration),
|
|
19
|
+
});
|
|
20
|
+
},
|
|
21
|
+
fromAmino: (a) => {
|
|
22
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
23
|
+
return tx_1.MsgCreateExchangeRate.fromPartial({
|
|
24
|
+
authority: (_a = a.authority) !== null && _a !== void 0 ? _a : "",
|
|
25
|
+
baseAssetType: (_b = a.base_asset_type) !== null && _b !== void 0 ? _b : 0,
|
|
26
|
+
baseAsset: (_c = a.base_asset) !== null && _c !== void 0 ? _c : "",
|
|
27
|
+
quoteAssetType: (_d = a.quote_asset_type) !== null && _d !== void 0 ? _d : 0,
|
|
28
|
+
quoteAsset: (_e = a.quote_asset) !== null && _e !== void 0 ? _e : "",
|
|
29
|
+
rate: (_f = a.rate) !== null && _f !== void 0 ? _f : "",
|
|
30
|
+
rateScale: (_g = a.rate_scale) !== null && _g !== void 0 ? _g : 0,
|
|
31
|
+
validityDuration: (0, helpers_1.aminoToDuration)(a.validity_duration),
|
|
32
|
+
});
|
|
33
|
+
},
|
|
34
|
+
};
|
|
35
|
+
exports.MsgUpdateExchangeRateAminoConverter = {
|
|
36
|
+
aminoType: "/verana.xr.v1.MsgUpdateExchangeRate",
|
|
37
|
+
toAmino: (m) => (0, helpers_1.clean)({
|
|
38
|
+
authority: m.authority || undefined,
|
|
39
|
+
operator: m.operator || undefined,
|
|
40
|
+
id: (0, helpers_1.u64ToStr)(m.id),
|
|
41
|
+
rate: m.rate || undefined,
|
|
42
|
+
}),
|
|
43
|
+
fromAmino: (a) => {
|
|
44
|
+
var _a, _b, _c;
|
|
45
|
+
return tx_1.MsgUpdateExchangeRate.fromPartial({
|
|
46
|
+
authority: (_a = a.authority) !== null && _a !== void 0 ? _a : "",
|
|
47
|
+
operator: (_b = a.operator) !== null && _b !== void 0 ? _b : "",
|
|
48
|
+
id: (0, helpers_1.strToU64)(a.id) != null ? Number((0, helpers_1.strToU64)(a.id).toString()) : 0,
|
|
49
|
+
rate: (_c = a.rate) !== null && _c !== void 0 ? _c : "",
|
|
50
|
+
});
|
|
51
|
+
},
|
|
52
|
+
};
|
|
53
|
+
exports.MsgToggleExchangeRateStateAminoConverter = {
|
|
54
|
+
aminoType: "/verana.xr.v1.MsgToggleExchangeRateState",
|
|
55
|
+
toAmino: (m) => (0, helpers_1.clean)({
|
|
56
|
+
authority: m.authority || undefined,
|
|
57
|
+
id: (0, helpers_1.u64ToStr)(m.id),
|
|
58
|
+
state: m.state ? true : undefined,
|
|
59
|
+
}),
|
|
60
|
+
fromAmino: (a) => {
|
|
61
|
+
var _a, _b;
|
|
62
|
+
return tx_1.MsgToggleExchangeRateState.fromPartial({
|
|
63
|
+
authority: (_a = a.authority) !== null && _a !== void 0 ? _a : "",
|
|
64
|
+
id: (0, helpers_1.strToU64)(a.id) != null ? Number((0, helpers_1.strToU64)(a.id).toString()) : 0,
|
|
65
|
+
state: (_b = a.state) !== null && _b !== void 0 ? _b : false,
|
|
66
|
+
});
|
|
67
|
+
},
|
|
68
|
+
};
|
|
@@ -13,7 +13,7 @@ export interface Coin {
|
|
|
13
13
|
/**
|
|
14
14
|
* DecCoin defines a token with a denomination and a decimal amount.
|
|
15
15
|
*
|
|
16
|
-
* NOTE: The amount field is
|
|
16
|
+
* NOTE: The amount field is a Dec which implements the custom method
|
|
17
17
|
* signatures required by gogoproto.
|
|
18
18
|
*/
|
|
19
19
|
export interface DecCoin {
|
|
@@ -812,6 +812,11 @@ export interface FieldOptions_FeatureSupport {
|
|
|
812
812
|
* not be able to override it.
|
|
813
813
|
*/
|
|
814
814
|
editionRemoved?: Edition | undefined;
|
|
815
|
+
/**
|
|
816
|
+
* The removal error text if this feature is used after the edition it was
|
|
817
|
+
* removed in.
|
|
818
|
+
*/
|
|
819
|
+
removalError?: string | undefined;
|
|
815
820
|
}
|
|
816
821
|
export interface OneofOptions {
|
|
817
822
|
/**
|
|
@@ -3702,7 +3702,7 @@ exports.FieldOptions_EditionDefault = {
|
|
|
3702
3702
|
},
|
|
3703
3703
|
};
|
|
3704
3704
|
function createBaseFieldOptions_FeatureSupport() {
|
|
3705
|
-
return { editionIntroduced: 0, editionDeprecated: 0, deprecationWarning: "", editionRemoved: 0 };
|
|
3705
|
+
return { editionIntroduced: 0, editionDeprecated: 0, deprecationWarning: "", editionRemoved: 0, removalError: "" };
|
|
3706
3706
|
}
|
|
3707
3707
|
exports.FieldOptions_FeatureSupport = {
|
|
3708
3708
|
encode(message, writer = _m0.Writer.create()) {
|
|
@@ -3718,6 +3718,9 @@ exports.FieldOptions_FeatureSupport = {
|
|
|
3718
3718
|
if (message.editionRemoved !== undefined && message.editionRemoved !== 0) {
|
|
3719
3719
|
writer.uint32(32).int32(message.editionRemoved);
|
|
3720
3720
|
}
|
|
3721
|
+
if (message.removalError !== undefined && message.removalError !== "") {
|
|
3722
|
+
writer.uint32(42).string(message.removalError);
|
|
3723
|
+
}
|
|
3721
3724
|
return writer;
|
|
3722
3725
|
},
|
|
3723
3726
|
decode(input, length) {
|
|
@@ -3751,6 +3754,12 @@ exports.FieldOptions_FeatureSupport = {
|
|
|
3751
3754
|
}
|
|
3752
3755
|
message.editionRemoved = reader.int32();
|
|
3753
3756
|
continue;
|
|
3757
|
+
case 5:
|
|
3758
|
+
if (tag !== 42) {
|
|
3759
|
+
break;
|
|
3760
|
+
}
|
|
3761
|
+
message.removalError = reader.string();
|
|
3762
|
+
continue;
|
|
3754
3763
|
}
|
|
3755
3764
|
if ((tag & 7) === 4 || tag === 0) {
|
|
3756
3765
|
break;
|
|
@@ -3765,6 +3774,7 @@ exports.FieldOptions_FeatureSupport = {
|
|
|
3765
3774
|
editionDeprecated: isSet(object.editionDeprecated) ? editionFromJSON(object.editionDeprecated) : 0,
|
|
3766
3775
|
deprecationWarning: isSet(object.deprecationWarning) ? globalThis.String(object.deprecationWarning) : "",
|
|
3767
3776
|
editionRemoved: isSet(object.editionRemoved) ? editionFromJSON(object.editionRemoved) : 0,
|
|
3777
|
+
removalError: isSet(object.removalError) ? globalThis.String(object.removalError) : "",
|
|
3768
3778
|
};
|
|
3769
3779
|
},
|
|
3770
3780
|
toJSON(message) {
|
|
@@ -3781,18 +3791,22 @@ exports.FieldOptions_FeatureSupport = {
|
|
|
3781
3791
|
if (message.editionRemoved !== undefined && message.editionRemoved !== 0) {
|
|
3782
3792
|
obj.editionRemoved = editionToJSON(message.editionRemoved);
|
|
3783
3793
|
}
|
|
3794
|
+
if (message.removalError !== undefined && message.removalError !== "") {
|
|
3795
|
+
obj.removalError = message.removalError;
|
|
3796
|
+
}
|
|
3784
3797
|
return obj;
|
|
3785
3798
|
},
|
|
3786
3799
|
create(base) {
|
|
3787
3800
|
return exports.FieldOptions_FeatureSupport.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
3788
3801
|
},
|
|
3789
3802
|
fromPartial(object) {
|
|
3790
|
-
var _a, _b, _c, _d;
|
|
3803
|
+
var _a, _b, _c, _d, _e;
|
|
3791
3804
|
const message = createBaseFieldOptions_FeatureSupport();
|
|
3792
3805
|
message.editionIntroduced = (_a = object.editionIntroduced) !== null && _a !== void 0 ? _a : 0;
|
|
3793
3806
|
message.editionDeprecated = (_b = object.editionDeprecated) !== null && _b !== void 0 ? _b : 0;
|
|
3794
3807
|
message.deprecationWarning = (_c = object.deprecationWarning) !== null && _c !== void 0 ? _c : "";
|
|
3795
3808
|
message.editionRemoved = (_d = object.editionRemoved) !== null && _d !== void 0 ? _d : 0;
|
|
3809
|
+
message.removalError = (_e = object.removalError) !== null && _e !== void 0 ? _e : "";
|
|
3796
3810
|
return message;
|
|
3797
3811
|
},
|
|
3798
3812
|
};
|
|
@@ -73,8 +73,8 @@ export declare const protobufPackage = "google.protobuf";
|
|
|
73
73
|
* {hour}, {min}, and {sec} are zero-padded to two digits each. The fractional
|
|
74
74
|
* seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution),
|
|
75
75
|
* are optional. The "Z" suffix indicates the timezone ("UTC"); the timezone
|
|
76
|
-
* is required. A
|
|
77
|
-
* "Z") when printing the Timestamp type and a
|
|
76
|
+
* is required. A ProtoJSON serializer should always use UTC (as indicated by
|
|
77
|
+
* "Z") when printing the Timestamp type and a ProtoJSON parser should be
|
|
78
78
|
* able to accept both UTC and other timezones (as indicated by an offset).
|
|
79
79
|
*
|
|
80
80
|
* For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past
|
|
@@ -94,7 +94,7 @@ export declare const protobufPackage = "google.protobuf";
|
|
|
94
94
|
export interface Timestamp {
|
|
95
95
|
/**
|
|
96
96
|
* Represents seconds of UTC time since Unix epoch 1970-01-01T00:00:00Z. Must
|
|
97
|
-
* be between -
|
|
97
|
+
* be between -62135596800 and 253402300799 inclusive (which corresponds to
|
|
98
98
|
* 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z).
|
|
99
99
|
*/
|
|
100
100
|
seconds: number;
|
|
@@ -1,10 +1,17 @@
|
|
|
1
1
|
import * as _m0 from "protobufjs/minimal";
|
|
2
2
|
import { Params } from "./params";
|
|
3
|
+
import { FeeGrant, OperatorAuthorization, VSOperatorAuthorization } from "./types";
|
|
3
4
|
export declare const protobufPackage = "verana.de.v1";
|
|
4
5
|
/** GenesisState defines the de module's genesis state. */
|
|
5
6
|
export interface GenesisState {
|
|
6
7
|
/** params defines all the parameters of the module. */
|
|
7
8
|
params: Params | undefined;
|
|
9
|
+
/** operator_authorizations is a list of all OperatorAuthorization objects */
|
|
10
|
+
operatorAuthorizations: OperatorAuthorization[];
|
|
11
|
+
/** fee_grants is a list of all FeeGrant objects */
|
|
12
|
+
feeGrants: FeeGrant[];
|
|
13
|
+
/** vs_operator_authorizations is a list of all VSOperatorAuthorization objects */
|
|
14
|
+
vsOperatorAuthorizations: VSOperatorAuthorization[];
|
|
8
15
|
}
|
|
9
16
|
export declare const GenesisState: {
|
|
10
17
|
encode(message: GenesisState, writer?: _m0.Writer): _m0.Writer;
|
|
@@ -42,15 +42,25 @@ exports.GenesisState = exports.protobufPackage = void 0;
|
|
|
42
42
|
/* eslint-disable */
|
|
43
43
|
const _m0 = __importStar(require("protobufjs/minimal"));
|
|
44
44
|
const params_1 = require("./params");
|
|
45
|
+
const types_1 = require("./types");
|
|
45
46
|
exports.protobufPackage = "verana.de.v1";
|
|
46
47
|
function createBaseGenesisState() {
|
|
47
|
-
return { params: undefined };
|
|
48
|
+
return { params: undefined, operatorAuthorizations: [], feeGrants: [], vsOperatorAuthorizations: [] };
|
|
48
49
|
}
|
|
49
50
|
exports.GenesisState = {
|
|
50
51
|
encode(message, writer = _m0.Writer.create()) {
|
|
51
52
|
if (message.params !== undefined) {
|
|
52
53
|
params_1.Params.encode(message.params, writer.uint32(10).fork()).ldelim();
|
|
53
54
|
}
|
|
55
|
+
for (const v of message.operatorAuthorizations) {
|
|
56
|
+
types_1.OperatorAuthorization.encode(v, writer.uint32(18).fork()).ldelim();
|
|
57
|
+
}
|
|
58
|
+
for (const v of message.feeGrants) {
|
|
59
|
+
types_1.FeeGrant.encode(v, writer.uint32(26).fork()).ldelim();
|
|
60
|
+
}
|
|
61
|
+
for (const v of message.vsOperatorAuthorizations) {
|
|
62
|
+
types_1.VSOperatorAuthorization.encode(v, writer.uint32(34).fork()).ldelim();
|
|
63
|
+
}
|
|
54
64
|
return writer;
|
|
55
65
|
},
|
|
56
66
|
decode(input, length) {
|
|
@@ -66,6 +76,24 @@ exports.GenesisState = {
|
|
|
66
76
|
}
|
|
67
77
|
message.params = params_1.Params.decode(reader, reader.uint32());
|
|
68
78
|
continue;
|
|
79
|
+
case 2:
|
|
80
|
+
if (tag !== 18) {
|
|
81
|
+
break;
|
|
82
|
+
}
|
|
83
|
+
message.operatorAuthorizations.push(types_1.OperatorAuthorization.decode(reader, reader.uint32()));
|
|
84
|
+
continue;
|
|
85
|
+
case 3:
|
|
86
|
+
if (tag !== 26) {
|
|
87
|
+
break;
|
|
88
|
+
}
|
|
89
|
+
message.feeGrants.push(types_1.FeeGrant.decode(reader, reader.uint32()));
|
|
90
|
+
continue;
|
|
91
|
+
case 4:
|
|
92
|
+
if (tag !== 34) {
|
|
93
|
+
break;
|
|
94
|
+
}
|
|
95
|
+
message.vsOperatorAuthorizations.push(types_1.VSOperatorAuthorization.decode(reader, reader.uint32()));
|
|
96
|
+
continue;
|
|
69
97
|
}
|
|
70
98
|
if ((tag & 7) === 4 || tag === 0) {
|
|
71
99
|
break;
|
|
@@ -75,23 +103,50 @@ exports.GenesisState = {
|
|
|
75
103
|
return message;
|
|
76
104
|
},
|
|
77
105
|
fromJSON(object) {
|
|
78
|
-
return {
|
|
106
|
+
return {
|
|
107
|
+
params: isSet(object.params) ? params_1.Params.fromJSON(object.params) : undefined,
|
|
108
|
+
operatorAuthorizations: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.operatorAuthorizations)
|
|
109
|
+
? object.operatorAuthorizations.map((e) => types_1.OperatorAuthorization.fromJSON(e))
|
|
110
|
+
: [],
|
|
111
|
+
feeGrants: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.feeGrants)
|
|
112
|
+
? object.feeGrants.map((e) => types_1.FeeGrant.fromJSON(e))
|
|
113
|
+
: [],
|
|
114
|
+
vsOperatorAuthorizations: globalThis.Array.isArray(object === null || object === void 0 ? void 0 : object.vsOperatorAuthorizations)
|
|
115
|
+
? object.vsOperatorAuthorizations.map((e) => types_1.VSOperatorAuthorization.fromJSON(e))
|
|
116
|
+
: [],
|
|
117
|
+
};
|
|
79
118
|
},
|
|
80
119
|
toJSON(message) {
|
|
120
|
+
var _a, _b, _c;
|
|
81
121
|
const obj = {};
|
|
82
122
|
if (message.params !== undefined) {
|
|
83
123
|
obj.params = params_1.Params.toJSON(message.params);
|
|
84
124
|
}
|
|
125
|
+
if ((_a = message.operatorAuthorizations) === null || _a === void 0 ? void 0 : _a.length) {
|
|
126
|
+
obj.operatorAuthorizations = message.operatorAuthorizations.map((e) => types_1.OperatorAuthorization.toJSON(e));
|
|
127
|
+
}
|
|
128
|
+
if ((_b = message.feeGrants) === null || _b === void 0 ? void 0 : _b.length) {
|
|
129
|
+
obj.feeGrants = message.feeGrants.map((e) => types_1.FeeGrant.toJSON(e));
|
|
130
|
+
}
|
|
131
|
+
if ((_c = message.vsOperatorAuthorizations) === null || _c === void 0 ? void 0 : _c.length) {
|
|
132
|
+
obj.vsOperatorAuthorizations = message.vsOperatorAuthorizations.map((e) => types_1.VSOperatorAuthorization.toJSON(e));
|
|
133
|
+
}
|
|
85
134
|
return obj;
|
|
86
135
|
},
|
|
87
136
|
create(base) {
|
|
88
137
|
return exports.GenesisState.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
89
138
|
},
|
|
90
139
|
fromPartial(object) {
|
|
140
|
+
var _a, _b, _c;
|
|
91
141
|
const message = createBaseGenesisState();
|
|
92
142
|
message.params = (object.params !== undefined && object.params !== null)
|
|
93
143
|
? params_1.Params.fromPartial(object.params)
|
|
94
144
|
: undefined;
|
|
145
|
+
message.operatorAuthorizations = ((_a = object.operatorAuthorizations) === null || _a === void 0 ? void 0 : _a.map((e) => types_1.OperatorAuthorization.fromPartial(e))) ||
|
|
146
|
+
[];
|
|
147
|
+
message.feeGrants = ((_b = object.feeGrants) === null || _b === void 0 ? void 0 : _b.map((e) => types_1.FeeGrant.fromPartial(e))) || [];
|
|
148
|
+
message.vsOperatorAuthorizations =
|
|
149
|
+
((_c = object.vsOperatorAuthorizations) === null || _c === void 0 ? void 0 : _c.map((e) => types_1.VSOperatorAuthorization.fromPartial(e))) || [];
|
|
95
150
|
return message;
|
|
96
151
|
},
|
|
97
152
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _m0 from "protobufjs/minimal";
|
|
2
2
|
import { Params } from "./params";
|
|
3
|
-
import { OperatorAuthorization } from "./types";
|
|
3
|
+
import { OperatorAuthorization, VSOperatorAuthorization } from "./types";
|
|
4
4
|
export declare const protobufPackage = "verana.de.v1";
|
|
5
5
|
/** QueryParamsRequest is request type for the Query/Params RPC method. */
|
|
6
6
|
export interface QueryParamsRequest {
|
|
@@ -29,6 +29,25 @@ export interface QueryListOperatorAuthorizationsRequest {
|
|
|
29
29
|
export interface QueryListOperatorAuthorizationsResponse {
|
|
30
30
|
operatorAuthorizations: OperatorAuthorization[];
|
|
31
31
|
}
|
|
32
|
+
/**
|
|
33
|
+
* QueryListVSOperatorAuthorizationsRequest is the request type for the
|
|
34
|
+
* Query/ListVSOperatorAuthorizations RPC method.
|
|
35
|
+
*/
|
|
36
|
+
export interface QueryListVSOperatorAuthorizationsRequest {
|
|
37
|
+
/** authority filters by the authority group that granted the authorization. */
|
|
38
|
+
authority: string;
|
|
39
|
+
/** vs_operator filters by the VS operator account. */
|
|
40
|
+
vsOperator: string;
|
|
41
|
+
/** response_max_size limits the number of results. Must be 1-1024, defaults to 64. */
|
|
42
|
+
responseMaxSize: number;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* QueryListVSOperatorAuthorizationsResponse is the response type for the
|
|
46
|
+
* Query/ListVSOperatorAuthorizations RPC method.
|
|
47
|
+
*/
|
|
48
|
+
export interface QueryListVSOperatorAuthorizationsResponse {
|
|
49
|
+
vsOperatorAuthorizations: VSOperatorAuthorization[];
|
|
50
|
+
}
|
|
32
51
|
export declare const QueryParamsRequest: {
|
|
33
52
|
encode(_: QueryParamsRequest, writer?: _m0.Writer): _m0.Writer;
|
|
34
53
|
decode(input: _m0.Reader | Uint8Array, length?: number): QueryParamsRequest;
|
|
@@ -61,12 +80,30 @@ export declare const QueryListOperatorAuthorizationsResponse: {
|
|
|
61
80
|
create<I extends Exact<DeepPartial<QueryListOperatorAuthorizationsResponse>, I>>(base?: I): QueryListOperatorAuthorizationsResponse;
|
|
62
81
|
fromPartial<I extends Exact<DeepPartial<QueryListOperatorAuthorizationsResponse>, I>>(object: I): QueryListOperatorAuthorizationsResponse;
|
|
63
82
|
};
|
|
83
|
+
export declare const QueryListVSOperatorAuthorizationsRequest: {
|
|
84
|
+
encode(message: QueryListVSOperatorAuthorizationsRequest, writer?: _m0.Writer): _m0.Writer;
|
|
85
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): QueryListVSOperatorAuthorizationsRequest;
|
|
86
|
+
fromJSON(object: any): QueryListVSOperatorAuthorizationsRequest;
|
|
87
|
+
toJSON(message: QueryListVSOperatorAuthorizationsRequest): unknown;
|
|
88
|
+
create<I extends Exact<DeepPartial<QueryListVSOperatorAuthorizationsRequest>, I>>(base?: I): QueryListVSOperatorAuthorizationsRequest;
|
|
89
|
+
fromPartial<I extends Exact<DeepPartial<QueryListVSOperatorAuthorizationsRequest>, I>>(object: I): QueryListVSOperatorAuthorizationsRequest;
|
|
90
|
+
};
|
|
91
|
+
export declare const QueryListVSOperatorAuthorizationsResponse: {
|
|
92
|
+
encode(message: QueryListVSOperatorAuthorizationsResponse, writer?: _m0.Writer): _m0.Writer;
|
|
93
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): QueryListVSOperatorAuthorizationsResponse;
|
|
94
|
+
fromJSON(object: any): QueryListVSOperatorAuthorizationsResponse;
|
|
95
|
+
toJSON(message: QueryListVSOperatorAuthorizationsResponse): unknown;
|
|
96
|
+
create<I extends Exact<DeepPartial<QueryListVSOperatorAuthorizationsResponse>, I>>(base?: I): QueryListVSOperatorAuthorizationsResponse;
|
|
97
|
+
fromPartial<I extends Exact<DeepPartial<QueryListVSOperatorAuthorizationsResponse>, I>>(object: I): QueryListVSOperatorAuthorizationsResponse;
|
|
98
|
+
};
|
|
64
99
|
/** Query defines the gRPC querier service. */
|
|
65
100
|
export interface Query {
|
|
66
101
|
/** Parameters queries the parameters of the module. */
|
|
67
102
|
Params(request: QueryParamsRequest): Promise<QueryParamsResponse>;
|
|
68
103
|
/** ListOperatorAuthorizations returns operator authorizations matching optional filters. */
|
|
69
104
|
ListOperatorAuthorizations(request: QueryListOperatorAuthorizationsRequest): Promise<QueryListOperatorAuthorizationsResponse>;
|
|
105
|
+
/** ListVSOperatorAuthorizations returns VS operator authorizations matching optional filters. */
|
|
106
|
+
ListVSOperatorAuthorizations(request: QueryListVSOperatorAuthorizationsRequest): Promise<QueryListVSOperatorAuthorizationsResponse>;
|
|
70
107
|
}
|
|
71
108
|
export declare const QueryServiceName = "verana.de.v1.Query";
|
|
72
109
|
export declare class QueryClientImpl implements Query {
|
|
@@ -77,6 +114,7 @@ export declare class QueryClientImpl implements Query {
|
|
|
77
114
|
});
|
|
78
115
|
Params(request: QueryParamsRequest): Promise<QueryParamsResponse>;
|
|
79
116
|
ListOperatorAuthorizations(request: QueryListOperatorAuthorizationsRequest): Promise<QueryListOperatorAuthorizationsResponse>;
|
|
117
|
+
ListVSOperatorAuthorizations(request: QueryListVSOperatorAuthorizationsRequest): Promise<QueryListVSOperatorAuthorizationsResponse>;
|
|
80
118
|
}
|
|
81
119
|
interface Rpc {
|
|
82
120
|
request(service: string, method: string, data: Uint8Array): Promise<Uint8Array>;
|