pub struct SystemStatusWebsocketItem {
pub id: String,
pub title: String,
pub state: String,
pub begin: u64,
pub end: u64,
pub href: String,
pub service_types: Vec<u32>,
pub product: Vec<u32>,
pub uid_suffix: Vec<u32>,
pub maintain_type: u32,
pub env: u32,
}Expand description
Represents a single system status/maintenance record in WebSocket stream
Fields§
§id: StringUnique identifier for the system status record
title: StringTitle of the system maintenance
state: StringSystem state (e.g., “completed”, “in_progress”, “scheduled”)
begin: u64Start time of system maintenance, timestamp in milliseconds
end: u64End time of system maintenance, timestamp in milliseconds. Before maintenance is completed, it is the expected end time; After maintenance is completed, it will be changed to the actual end time.
href: StringHyperlink to system maintenance details. Default value is empty string
service_types: Vec<u32>Service types affected by the maintenance
product: Vec<u32>Products affected by the maintenance
uid_suffix: Vec<u32>Affected UID tail numbers
maintain_type: u32Maintenance type
env: u32Environment
Implementations§
Source§impl SystemStatusWebsocketItem
impl SystemStatusWebsocketItem
Sourcepub fn new(
id: &str,
title: &str,
state: &str,
begin: u64,
end: u64,
href: &str,
service_types: Vec<u32>,
product: Vec<u32>,
uid_suffix: Vec<u32>,
maintain_type: u32,
env: u32,
) -> Self
pub fn new( id: &str, title: &str, state: &str, begin: u64, end: u64, href: &str, service_types: Vec<u32>, product: Vec<u32>, uid_suffix: Vec<u32>, maintain_type: u32, env: u32, ) -> Self
Constructs a new SystemStatusWebsocketItem with specified parameters
Sourcepub fn is_in_progress(&self) -> bool
pub fn is_in_progress(&self) -> bool
Returns true if the maintenance is currently in progress
Sourcepub fn is_scheduled(&self) -> bool
pub fn is_scheduled(&self) -> bool
Returns true if the maintenance is scheduled for the future
Sourcepub fn is_completed(&self) -> bool
pub fn is_completed(&self) -> bool
Returns true if the maintenance has been completed
Sourcepub fn affects_service_type(&self, service_type: u32) -> bool
pub fn affects_service_type(&self, service_type: u32) -> bool
Returns true if the maintenance affects the given service type
Sourcepub fn affects_product(&self, product_id: u32) -> bool
pub fn affects_product(&self, product_id: u32) -> bool
Returns true if the maintenance affects the given product
Sourcepub fn affects_uid_suffix(&self, uid_suffix: u32) -> bool
pub fn affects_uid_suffix(&self, uid_suffix: u32) -> bool
Returns true if the maintenance affects the given UID suffix
Trait Implementations§
Source§impl Clone for SystemStatusWebsocketItem
impl Clone for SystemStatusWebsocketItem
Source§fn clone(&self) -> SystemStatusWebsocketItem
fn clone(&self) -> SystemStatusWebsocketItem
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more