use crate::StreamInfo;
use serde::{Deserialize, Serialize};
#[derive(Debug, Serialize, Deserialize, Clone)]
pub struct StreamResult {
url: String,
info: Option<StreamInfo>,
log: Vec<String>,
}
impl StreamResult {
pub fn new(url: &str, info: Option<StreamInfo>, log: Vec<String>) -> Self {
StreamResult {
url: url.to_string(),
info,
log,
}
}
pub fn url(&self) -> &str {
&self.url
}
pub fn log(&self) -> &Vec<String> {
&self.log
}
pub fn info(&self) -> &Option<StreamInfo> {
&self.info
}
}