openehr-rm 0.0.128

openEHR RM Reference Model, generated from BMM: generations v1_1 (RM 1.1.0) and v1_2 (RM 1.2.0, current)
Documentation
// @generated by openehr-codegen from BMM (`MESSAGE`) — DO NOT EDIT.
// SPDX-FileCopyrightText: Cadasto B.V.
// SPDX-FileCopyrightText: openEHR Foundation
// SPDX-License-Identifier: Apache-2.0

//! The openEHR `MESSAGE` spec class, generated from the vendored BMM
//! meta-model.

use crate::v1_1::common::generic::audit_details::AuditDetails;
use crate::v1_1::common::generic::party_proxy::PartyProxy;
use crate::v1_1::ehr_extract::message::message_content::MessageContent;

/// A “message” is an authored, possibly signed, piece of content intended for one or more recipients.
///
/// Since the recipient may or may not be known directly, recipients are specified in the `ADDRESSED_MESSAGE` class.
#[doc(alias = "MESSAGE")]
#[derive(Debug, Clone, PartialEq)]
pub struct Message {
    /// Details of who actually created the message and when. This is the person who entered the data or otherwise caused the message to be created, or might be a piece of software.
    pub audit: AuditDetails,
    /// Party responsible for the message content, who may or may not be technically responsible for its creation (e.g. by data entry etc).
    pub author: PartyProxy,
    /// Content of the message.
    pub content: MessageContent,
    /// Optional signature by the author of message content in openPGP format.
    ///
    /// The signature is created as a Hash and optional signing of the serialisation of this message object with this signature field Void.
    pub signature: Option<String>,
}