Mountain/ApplicationState/DTO/
OutputChannelStateDTO.rs

1//! # OutputChannelStateDTO
2//!
3//! Defines the Data Transfer Object for storing the state of a single output
4//! channel.
5
6#![allow(non_snake_case, non_camel_case_types)]
7
8use serde::{Deserialize, Serialize};
9
10/// Represents the complete state of a single output channel, including its
11/// buffered content and visibility status.
12#[derive(Serialize, Deserialize, Clone, Debug, Default)]
13#[serde(rename_all = "PascalCase")]
14pub struct OutputChannelStateDTO {
15	pub Name:String,
16
17	pub LanguageIdentifier:Option<String>,
18
19	pub Buffer:String,
20
21	pub IsVisible:bool,
22}
23
24impl OutputChannelStateDTO {
25	/// Creates a new `OutputChannelStateDTO`.
26	pub fn Create(Name:&str, LanguageIdentifier:Option<String>) -> Self {
27		Self { Name:Name.to_string(), LanguageIdentifier, ..Default::default() }
28	}
29}