def sanitise_conf(conf)
      conf[:username] ||= 'admin'
      conf[:password] ||= 'admin'
      conf[:protocol] ||= 'http'
      conf[:host] ||= 'localhost'
      conf[:port] ||= 4502
      conf[:timeout] ||= 300
      # handle custom configuration value being passed as a String
      # e.g. when the values are passed via environment variables
      conf[:port] = conf[:port].to_i
      conf[:timeout] = conf[:timeout].to_i
      conf[:verify_ssl] = conf[:verify_ssl] == 'true' if conf[:verify_ssl].is_a? String
      conf[:debug] = conf[:debug] == 'true' if conf[:debug].is_a? String
    end
def sanitise_conf(conf)
      conf[:username] ||= 'admin'
      conf[:password] ||= 'admin'
      conf[:protocol] ||= 'http'
      conf[:host] ||= 'localhost'
      conf[:port] ||= 4502
      conf[:timeout] ||= 300
      # handle custom configuration value being passed as a String
      # e.g. when the values are passed via environment variables
      conf[:port] = conf[:port].to_i
      conf[:timeout] = conf[:timeout].to_i
      conf[:verify_ssl] = conf[:verify_ssl] == 'true' if conf[:verify_ssl].is_a? String
      conf[:debug] = conf[:debug] == 'true' if conf[:debug].is_a? String
    end
Initialise a Ruby AEM instance.

 @param conf configuration hash of the following configuration values:
 - username: username used to authenticate to AEM instance, default: 'admin'
 - password: password used to authenticate to AEM instance, default: 'admin'
 - protocol: AEM instance protocol (http or https), default: 'http'
 - host: AEM instance host name, default: 'localhost'
 - port: AEM instance port, default: 4502
 - timeout: connection timeout in seconds, default: 300 seconds
 - debug: if true, then additional debug messages will be included, default: false
 @return new RubyAem::Aem instance
 Set default configuration values and handle numeric/boolean String values