1 | import type { AnyJson, Registry } from '@polkadot/types-codec/types';
|
2 | import type { AllConvictions } from '../interfaces/democracy/definitions.js';
|
3 | import type { Conviction } from '../interfaces/democracy/index.js';
|
4 | import type { ArrayElementType } from '../types/index.js';
|
5 | import { U8aFixed } from '@polkadot/types-codec';
|
6 | interface VoteType {
|
7 | aye: boolean;
|
8 | conviction?: number | ArrayElementType<typeof AllConvictions>;
|
9 | }
|
10 | type InputTypes = boolean | number | Boolean | Uint8Array | VoteType;
|
11 |
|
12 |
|
13 |
|
14 |
|
15 |
|
16 | export declare class GenericVote extends U8aFixed {
|
17 | #private;
|
18 | constructor(registry: Registry, value?: InputTypes);
|
19 | /**
|
20 | * @description returns a V2 conviction
|
21 | */
|
22 | get conviction(): Conviction;
|
23 | /**
|
24 | * @description true if the wrapped value is a positive vote
|
25 | */
|
26 | get isAye(): boolean;
|
27 | /**
|
28 | * @description true if the wrapped value is a negative vote
|
29 | */
|
30 | get isNay(): boolean;
|
31 | /**
|
32 | * @description Converts the Object to to a human-friendly JSON, with additional fields, expansion and formatting of information
|
33 | */
|
34 | toHuman(isExpanded?: boolean): AnyJson;
|
35 | /**
|
36 | * @description Converts the value in a best-fit primitive form
|
37 | */
|
38 | toPrimitive(): any;
|
39 | /**
|
40 | * @description Returns the base runtime type name for this instance
|
41 | */
|
42 | toRawType(): string;
|
43 | }
|
44 | export {};
|