fireblocks_sdk/models/
block_info.rs

1// Fireblocks API
2//
3// Fireblocks provides a suite of applications to manage digital asset operations and a complete development platform to build your business on the blockchain.  - Visit our website for more information: [Fireblocks Website](https://fireblocks.com) - Visit our developer docs: [Fireblocks DevPortal](https://developers.fireblocks.com)
4//
5// The version of the OpenAPI document: 1.8.0
6// Contact: developers@fireblocks.com
7// Generated by: https://openapi-generator.tech
8
9use {
10    crate::models,
11    serde::{Deserialize, Serialize},
12};
13
14/// BlockInfo : The block hash and height of the block that this transaction was
15/// mined in.      **Note**: If an outgoing transaction uses the destinations
16/// object with more than one value in the array, blockHash is set to null.
17#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
18pub struct BlockInfo {
19    #[serde(rename = "blockHeight", skip_serializing_if = "Option::is_none")]
20    pub block_height: Option<String>,
21    #[serde(
22        rename = "blockHash",
23        default,
24        with = "::serde_with::rust::double_option",
25        skip_serializing_if = "Option::is_none"
26    )]
27    pub block_hash: Option<Option<String>>,
28}
29
30impl BlockInfo {
31    /// The block hash and height of the block that this transaction was mined
32    /// in.      **Note**: If an outgoing transaction uses the destinations
33    /// object with more than one value in the array, blockHash is set to null.
34    pub fn new() -> BlockInfo {
35        BlockInfo {
36            block_height: None,
37            block_hash: None,
38        }
39    }
40}