fn new() -> AppConfigurationParser {
        let default_mac_addr = utils::result_or_error(
            get_first_mac(),
            EXIT_CODE_NETWORK_ERROR,
            "unable to get any network interface MAC address");

        AppConfigurationParser {
            arrow_mac:          default_mac_addr,
            arrow_svc_addr:     String::new(),
            ca_certificates:    Vec::new(),
            rtsp_services:      Vec::new(),
            mjpeg_services:     Vec::new(),
            http_services:      Vec::new(),
            tcp_services:       Vec::new(),
            logger_type:        LoggerType::Syslog,
            config_file:        CONFIG_FILE.to_string(),
            state_file:         STATE_FILE.to_string(),
            rtsp_paths_file:    RTSP_PATHS_FILE.to_string(),
            mjpeg_paths_file:   MJPEG_PATHS_FILE.to_string(),
            log_file:           String::new(),
            discovery:          false,
            verbose:            false,
            diagnostic_mode:    false,
            log_file_size:      10 * 1024,
            log_file_rotations: 1,
        }
    }
/// Create a new app configuration parser.
Create a new app configuration parser.
Create a new app configuration parser .
fn new() -> AppConfigurationParser {
        let default_mac_addr = utils::result_or_error(
            get_first_mac(),
            EXIT_CODE_NETWORK_ERROR,
            "unable to get any network interface MAC address");
        AppConfigurationParser {
            arrow_mac:          default_mac_addr,
            arrow_svc_addr:     String::new(),
            ca_certificates:    Vec::new(),
            rtsp_services:      Vec::new(),
            mjpeg_services:     Vec::new(),
            http_services:      Vec::new(),
            tcp_services:       Vec::new(),
            logger_type:        LoggerType::Syslog,
            config_file:        CONFIG_FILE.to_string(),
            state_file:         STATE_FILE.to_string(),
            rtsp_paths_file:    RTSP_PATHS_FILE.to_string(),
            mjpeg_paths_file:   MJPEG_PATHS_FILE.to_string(),
            log_file:           String::new(),
            discovery:          false,
            verbose:            false,
            diagnostic_mode:    false,
            log_file_size:      10 * 1024,
            log_file_rotations: 1,
        }
    }
fn new ( ) -> AppConfigurationParser { let default_mac_addr = utils :: result_or_error ( get_first_mac ( ) , EXIT_CODE_NETWORK_ERROR , " " ) ; AppConfigurationParser { arrow_mac : default_mac_addr , arrow_svc_addr : String :: new ( ) , ca_certificates : Vec :: new ( ) , rtsp_services : Vec :: new ( ) , mjpeg_services : Vec :: new ( ) , http_services : Vec :: new ( ) , tcp_services : Vec :: new ( ) , logger_type : LoggerType :: Syslog , config_file : CONFIG_FILE . to_string ( ) , state_file : STATE_FILE . to_string ( ) , rtsp_paths_file : RTSP_PATHS_FILE . to_string ( ) , mjpeg_paths_file : MJPEG_PATHS_FILE . to_string ( ) , log_file : String :: new ( ) , discovery : false , verbose : false , diagnostic_mode : false , log_file_size : 10 * 1024 , log_file_rotations : 1 , } }
Create a new app configuration parser.
Create a new app configuration parser .