Skip to main content

blockfrost_openapi/models/
tx_content_stake_addr_inner.rs

1use crate::models;
2use serde::{Deserialize, Serialize};
3
4#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
5pub struct TxContentStakeAddrInner {
6    /// Index of the certificate within the transaction
7    #[serde(rename = "cert_index")]
8    pub cert_index: i32,
9    /// Delegation stake address
10    #[serde(rename = "address")]
11    pub address: String,
12    /// Registration boolean, false if deregistration
13    #[serde(rename = "registration")]
14    pub registration: bool,
15}
16
17impl TxContentStakeAddrInner {
18    pub fn new(cert_index: i32, address: String, registration: bool) -> TxContentStakeAddrInner {
19        TxContentStakeAddrInner {
20            cert_index,
21            address,
22            registration,
23        }
24    }
25}
26