1
2
3
4
5
6
7
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
/*
* Indexer
*
* Algorand ledger analytics API.
*
* The version of the OpenAPI document: 2.0
*
* Generated by: https://openapi-generator.tech
*/
use algonaut_encoding::Bytes;
/// TransactionKeyreg : Fields for a keyreg transaction. Definition: data/transactions/keyreg.go : KeyregTxnFields
#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
pub struct TransactionKeyreg {
/// \\[nonpart\\] Mark the account as participating or non-participating.
#[serde(rename = "non-participation", skip_serializing_if = "Option::is_none")]
pub non_participation: Option<bool>,
/// \\[selkey\\] Public key used with the Verified Random Function (VRF) result during committee selection.
#[serde(
rename = "selection-participation-key",
skip_serializing_if = "Option::is_none"
)]
pub selection_participation_key: Option<Bytes>,
/// \\[sprfkey\\] State proof key used in key registration transactions.
#[serde(rename = "state-proof-key", skip_serializing_if = "Option::is_none")]
pub state_proof_key: Option<Bytes>,
/// \\[votefst\\] First round this participation key is valid.
#[serde(rename = "vote-first-valid", skip_serializing_if = "Option::is_none")]
pub vote_first_valid: Option<u64>,
/// \\[votekd\\] Number of subkeys in each batch of participation keys.
#[serde(rename = "vote-key-dilution", skip_serializing_if = "Option::is_none")]
pub vote_key_dilution: Option<u64>,
/// \\[votelst\\] Last round this participation key is valid.
#[serde(rename = "vote-last-valid", skip_serializing_if = "Option::is_none")]
pub vote_last_valid: Option<u64>,
/// \\[votekey\\] Participation public key used in key registration transactions.
#[serde(
rename = "vote-participation-key",
skip_serializing_if = "Option::is_none"
)]
pub vote_participation_key: Option<Bytes>,
}
impl TransactionKeyreg {
/// Fields for a keyreg transaction. Definition: data/transactions/keyreg.go : KeyregTxnFields
pub fn new() -> TransactionKeyreg {
TransactionKeyreg {
non_participation: None,
selection_participation_key: None,
state_proof_key: None,
vote_first_valid: None,
vote_key_dilution: None,
vote_last_valid: None,
vote_participation_key: None,
}
}
}