fn validate(&self) -> Result<(), String> {
        if self.is_tls_enabled.is_none()    // is_tls_enabled not specified
            || self.controller_uri.is_none()    // controller_uri not specified
            || self
                .controller_uri
                .as_ref()
                .unwrap()
                .scheme()
                .unwrap_or_default()
                .is_empty()
        {
            // at least one option has not been specified or uri has no scheme,
            // therefore cannot have a conflict with is_tls_enabled
            return Ok(());
        }
        let is_tls_enabled = self.is_tls_enabled.unwrap();
        let scheme_is_type_tls = self.default_is_tls_enabled();
        if is_tls_enabled != scheme_is_type_tls {
            Err(format!(
                "is_tls_enabled option {} does not match scheme in uri {}",
                is_tls_enabled,
                self.controller_uri.as_ref().unwrap().to_string()
            ))
        } else {
            Ok(())
        }
    }
/// validate the builder before returning it
///
/// if is_tls_enabled, controller_uri have been set and if controller_uri
/// contains a scheme, then verify that the uri scheme matches the is_tls_enabled
/// value.
validate the builder before returning it
if is_tls_enabled, controller_uri have been set and if controller_uri
contains a scheme, then verify that the uri scheme matches the is_tls_enabled
value.
validate the builder before returning it if is_tls_enabled controller_uri have been set and if controller_uri contains a scheme then verify that the uri scheme matches the is_tls_enabled value .
fn validate(&self) -> Result<(), String> {
        if self.is_tls_enabled.is_none()    // is_tls_enabled not specified
            || self.controller_uri.is_none()    // controller_uri not specified
            || self
                .controller_uri
                .as_ref()
                .unwrap()
                .scheme()
                .unwrap_or_default()
                .is_empty()
        {
            // at least one option has not been specified or uri has no scheme,
            // therefore cannot have a conflict with is_tls_enabled
            return Ok(());
        }
        let is_tls_enabled = self.is_tls_enabled.unwrap();
        let scheme_is_type_tls = self.default_is_tls_enabled();
        if is_tls_enabled != scheme_is_type_tls {
            Err(format!(
                "is_tls_enabled option {} does not match scheme in uri {}",
                is_tls_enabled,
                self.controller_uri.as_ref().unwrap().to_string()
            ))
        } else {
            Ok(())
        }
    }
fn validate ( & self ) -> Result < ( ) , String > { if self . is_tls_enabled . is_none ( ) // is_tls_enabled not specified || self . controller_uri . is_none ( ) // controller_uri not specified || self . controller_uri . as_ref ( ) . unwrap ( ) . scheme ( ) . unwrap_or_default ( ) . is_empty ( ) { // at least one option has not been specified or uri has no scheme, // therefore cannot have a conflict with is_tls_enabled return Ok ( ( ) ) ; } let is_tls_enabled = self . is_tls_enabled . unwrap ( ) ; let scheme_is_type_tls = self . default_is_tls_enabled ( ) ; if is_tls_enabled != scheme_is_type_tls { Err ( format ! ( " " is_tls_enabled self controller_uri as_ref ( ) unwrap ( ) to_string ( ) ) ) } else { Ok ( ( ) ) } }
validate the builder before returning it
if is_tls_enabled, controller_uri have been set and if controller_uri
contains a scheme, then verify that the uri scheme matches the is_tls_enabled
value.
validate the builder before returning it if is_tls_enabled controller_uri have been set and if controller_uri contains a scheme then verify that the uri scheme matches the is_tls_enabled value .
&self
&self