Skip to main content

blockfrost_openapi/models/
protocol_message.rs

1use crate::models;
2use serde::{Deserialize, Serialize};
3
4/// ProtocolMessage : ProtocolMessage represents a message that is signed (or verified) by the Mithril protocol
5#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
6pub struct ProtocolMessage {
7    #[serde(rename = "message_parts")]
8    pub message_parts: models::ProtocolMessageParts,
9}
10
11impl ProtocolMessage {
12    /// ProtocolMessage represents a message that is signed (or verified) by the Mithril protocol
13    pub fn new(message_parts: models::ProtocolMessageParts) -> ProtocolMessage {
14        ProtocolMessage {
15            message_parts,
16        }
17    }
18}
19