#[derive(Debug, Clone, PartialEq, Eq)]
#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
pub struct HeartbeatResponse<CustomDataType = crate::NoCustomData> {
#[cfg_attr(feature = "serde", serde(rename = "currentTime"))]
pub current_time: crate::OcppTimestamp,
#[cfg_attr(feature = "serde", serde(rename = "customData"))]
#[cfg_attr(feature = "serde", serde(skip_serializing_if = "Option::is_none"))]
pub custom_data: Option<CustomDataType>,
}
impl<CustomDataType> crate::Action for HeartbeatResponse<CustomDataType> {
const ACTION: &'static str = "Heartbeat";
}
#[cfg(feature = "validate")]
impl<CustomDataType> crate::validate::Validate for HeartbeatResponse<CustomDataType> {
fn validate(&self) -> Result<(), crate::validate::ValidationError> {
Ok(())
}
}