original_string: public function getResponseDatabase()
      {
          if ((!$this->_responsesDb) && $this->hasResponseDatabase()) {
              $adapter = $this['responses']['adapter'];
  
              if (isset($this['responses'], $this['responses']['params'])) {
                  $options = $this['responses']['params'];
  
                  if (! isset(
                          $options['charset'],
                          $options['host'],
                          $options['dbname'],
                          $options['username'],
                          $options['password']
                          )) {
  
                      $db = \Zend_Registry::get('db');
  
                      if ($db instanceof \Zend_Db_Adapter_Abstract) {
                          $options = $options + $db->getConfig();
                      }
                  }
                  $this->_responsesDb = \Zend_Db::factory($adapter, $options);
              } else {
                  $db = \Zend_Registry::get('db');
  
                  if ($db instanceof \Zend_Db_Adapter_Abstract) {
                      $this->_responsesDb = $db;
                  }
              }
          }
  
          return $this->_responsesDb;
      }
code: public function getResponseDatabase()
      {
          if ((!$this->_responsesDb) && $this->hasResponseDatabase()) {
              $adapter = $this['responses']['adapter'];
  
              if (isset($this['responses'], $this['responses']['params'])) {
                  $options = $this['responses']['params'];
  
                  if (! isset(
                          $options['charset'],
                          $options['host'],
                          $options['dbname'],
                          $options['username'],
                          $options['password']
                          )) {
  
                      $db = \Zend_Registry::get('db');
  
                      if ($db instanceof \Zend_Db_Adapter_Abstract) {
                          $options = $options + $db->getConfig();
                      }
                  }
                  $this->_responsesDb = \Zend_Db::factory($adapter, $options);
              } else {
                  $db = \Zend_Registry::get('db');
  
                  if ($db instanceof \Zend_Db_Adapter_Abstract) {
                      $this->_responsesDb = $db;
                  }
              }
          }
  
          return $this->_responsesDb;
      }
code_tokens: public function getResponseDatabase ( ) { if ( ( ! $ this -> _responsesDb ) && $ this -> hasResponseDatabase ( ) ) { $ adapter = $ this [ 'responses' ] [ 'adapter' ] ; if ( isset ( $ this [ 'responses' ] , $ this [ 'responses' ] [ 'params' ] ) ) { $ options = $ this [ 'responses' ] [ 'params' ] ; if ( ! isset ( $ options [ 'charset' ] , $ options [ 'host' ] , $ options [ 'dbname' ] , $ options [ 'username' ] , $ options [ 'password' ] ) ) { $ db = \ Zend_Registry :: get ( 'db' ) ; if ( $ db instanceof \ Zend_Db_Adapter_Abstract ) { $ options = $ options + $ db -> getConfig ( ) ; } } $ this -> _responsesDb = \ Zend_Db :: factory ( $ adapter , $ options ) ; } else { $ db = \ Zend_Registry :: get ( 'db' ) ; if ( $ db instanceof \ Zend_Db_Adapter_Abstract ) { $ this -> _responsesDb = $ db ; } } } return $ this -> _responsesDb ; }
docstring: The response database with a table with one row for each token answer.
  
  @return \Zend_Db_Adapter_Abstract
docstring_tokens: The response database with a table with one row for each token answer .