/*
 * Cloud Hypervisor API
 *
 * Local HTTP based API for managing and inspecting a cloud-hypervisor virtual machine.
 *
 * The version of the OpenAPI document: 0.3.0
 *
 * Generated by: https://openapi-generator.tech
 */

use crate::models;
use serde::{Deserialize, Serialize};

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct DebugConsoleConfig {
    #[serde(rename = "file", skip_serializing_if = "Option::is_none")]
    pub file: Option<String>,
    #[serde(rename = "mode")]
    pub mode: models::ConsoleMode,
    #[serde(rename = "iobase", skip_serializing_if = "Option::is_none")]
    pub iobase: Option<i32>,
}

impl DebugConsoleConfig {
    pub fn new(mode: models::ConsoleMode) -> DebugConsoleConfig {
        DebugConsoleConfig {
            file: None,
            mode,
            iobase: None,
        }
    }
}
