/**
  * Construct the Google Client.
  *
  * @param $config Google_Config or string for the ini file to load
  */
 public function __construct($config = null)
 {
     if (is_string($config) && strlen($config)) {
         $config = new App_Google_Config($config);
     } else {
         if (!$config instanceof App_Google_Config) {
             $config = new App_Google_Config();
             if ($this->isAppEngine()) {
                 // Automatically use Memcache if we're in AppEngine.
                 $config->setCacheClass('App_Google_Cache_Memcache');
             }
             if (version_compare(phpversion(), "5.3.4", "<=") || $this->isAppEngine()) {
                 // Automatically disable compress.zlib, as currently unsupported.
                 $config->setClassConfig('App_Google_Http_Request', 'disable_gzip', true);
             }
         }
     }
     if ($config->getIoClass() == App_Google_Config::USE_AUTO_IO_SELECTION) {
         if (function_exists('curl_version') && function_exists('curl_exec') && !$this->isAppEngine()) {
             $config->setIoClass("App_Google_IO_Curl");
         } else {
             $config->setIoClass("App_Google_IO_Stream");
         }
     }
     $this->config = $config;
 }