original_string: public function set_many(array $keyvaluearray) {
          $pairs = [];
          foreach ($keyvaluearray as $pair) {
              $pairs[$pair['key']] = $pair['value'];
          }
          if ($this->redis->hMSet($this->hash, $pairs)) {
              return count($pairs);
          }
          return 0;
      }
code: public function set_many(array $keyvaluearray) {
          $pairs = [];
          foreach ($keyvaluearray as $pair) {
              $pairs[$pair['key']] = $pair['value'];
          }
          if ($this->redis->hMSet($this->hash, $pairs)) {
              return count($pairs);
          }
          return 0;
      }
code_tokens: public function set_many ( array $ keyvaluearray ) { $ pairs = [ ] ; foreach ( $ keyvaluearray as $ pair ) { $ pairs [ $ pair [ 'key' ] ] = $ pair [ 'value' ] ; } if ( $ this -> redis -> hMSet ( $ this -> hash , $ pairs ) ) { return count ( $ pairs ) ; } return 0 ; }
docstring: Set the values of many keys.
  
  @param array $keyvaluearray An array of key/value pairs. Each item in the array is an associative array
  with two keys, 'key' and 'value'.
  @return int The number of key/value pairs successfuly set.
docstring_tokens: Set the values of many keys .