pub fn update_from_config_options(&mut self, config_options: &PostgresConfigOptions) {
        if self.host.is_none() && config_options.host.is_some() {
            self.host = config_options.host.clone();
        }
        if self.port.is_none() && config_options.port.is_some() {
            self.port = config_options.port;
        }
        if self.user.is_none() && config_options.user.is_some() {
            self.user = config_options.user.clone();
        }
        if self.password.is_none() && config_options.password.is_some() {
            self.password = config_options.password.clone();
        }
       if self.database.is_none() && config_options.database.is_some() {
            self.database = config_options.database.clone();
        }
        if self.init.is_empty() && !config_options.init.is_empty() {
            self.init.extend(config_options.init.iter().cloned());
        }
        if self.timeout.is_none() && config_options.timeout.is_some() {
            self.timeout = config_options.timeout;
        }
    }
//fill any values that are set in config options and not overriden
fill any values that are set in config options and not overriden
fill any values that are set in config options and not overriden
pub fn update_from_config_options(&mut self, config_options: &PostgresConfigOptions) {
        if self.host.is_none() && config_options.host.is_some() {
            self.host = config_options.host.clone();
        }
        if self.port.is_none() && config_options.port.is_some() {
            self.port = config_options.port;
        }
        if self.user.is_none() && config_options.user.is_some() {
            self.user = config_options.user.clone();
        }
        if self.password.is_none() && config_options.password.is_some() {
            self.password = config_options.password.clone();
        }
       if self.database.is_none() && config_options.database.is_some() {
            self.database = config_options.database.clone();
        }
        if self.init.is_empty() && !config_options.init.is_empty() {
            self.init.extend(config_options.init.iter().cloned());
        }
        if self.timeout.is_none() && config_options.timeout.is_some() {
            self.timeout = config_options.timeout;
        }
    }
pub fn update_from_config_options ( & mut self , config_options : & PostgresConfigOptions ) { if self . host . is_none ( ) && config_options . host . is_some ( ) { self . host = config_options . host . clone ( ) ; } if self . port . is_none ( ) && config_options . port . is_some ( ) { self . port = config_options . port ; } if self . user . is_none ( ) && config_options . user . is_some ( ) { self . user = config_options . user . clone ( ) ; } if self . password . is_none ( ) && config_options . password . is_some ( ) { self . password = config_options . password . clone ( ) ; } if self . database . is_none ( ) && config_options . database . is_some ( ) { self . database = config_options . database . clone ( ) ; } if self . init . is_empty ( ) && ! config_options . init . is_empty ( ) { self . init . extend ( config_options . init . iter ( ) . cloned ( ) ) ; } if self . timeout . is_none ( ) && config_options . timeout . is_some ( ) { self . timeout = config_options . timeout ; } }
fill any values that are set in config options and not overriden
fill any values that are set in config options and not overriden
&mut self
config_options
&PostgresConfigOptions
&mut self
config_options
&PostgresConfigOptions