original_string: public static function config($key, $config = null)
      {
          deprecationWarning(
              get_called_class() . '::config() is deprecated. ' .
              'Use setConfig()/getConfig() instead.'
          );
  
          if ($config !== null || is_array($key)) {
              static::setConfig($key, $config);
  
              return null;
          }
  
          return static::getConfig($key);
      }
code: public static function config($key, $config = null)
      {
          deprecationWarning(
              get_called_class() . '::config() is deprecated. ' .
              'Use setConfig()/getConfig() instead.'
          );
  
          if ($config !== null || is_array($key)) {
              static::setConfig($key, $config);
  
              return null;
          }
  
          return static::getConfig($key);
      }
code_tokens: public static function config ( $ key , $ config = null ) { deprecationWarning ( get_called_class ( ) . '::config() is deprecated. ' . 'Use setConfig()/getConfig() instead.' ) ; if ( $ config !== null || is_array ( $ key ) ) { static :: setConfig ( $ key , $ config ) ; return null ; } return static :: getConfig ( $ key ) ; }
docstring: This method can be used to define configuration adapters for an application
  or read existing configuration.
  
  To change an adapter's configuration at runtime, first drop the adapter and then
  reconfigure it.
  
  Adapters will not be constructed until the first operation is done.
  
  ### Usage
  
  Assuming that the class' name is `Cache` the following scenarios
  are supported:
  
  Reading config data back:
  
  ```
  Cache::config('default');
  ```
  
  Setting a cache engine up.
  
  ```
  Cache::config('default', $settings);
  ```
  
  Injecting a constructed adapter in:
  
  ```
  Cache::config('default', $instance);
  ```
  
  Configure multiple adapters at once:
  
  ```
  Cache::config($arrayOfConfig);
  ```
  
  @deprecated 3.4.0 Use setConfig()/getConfig() instead.
  @param string|array $key The name of the configuration, or an array of multiple configs.
  @param array|null $config An array of name => configuration data for adapter.
  @return array|null Null when adding configuration or an array of configuration data when reading.
  @throws \BadMethodCallException When trying to modify an existing config.
docstring_tokens: This method can be used to define configuration adapters for an application or read existing configuration .