original_string: protected function filterAndSeparateForeignKeys($foreignKeys, $table)
      {
          $results = ['local' => [], 'remote' => []];
          foreach ($foreignKeys as $foreignKey) {
              if ($foreignKey->TABLE_NAME == $table) {
                  $results['local'][] = $foreignKey;
              }
              if ($foreignKey->REFERENCED_TABLE_NAME == $table) {
                  $results['remote'][] = $foreignKey;
              }
          }
  
          return $results;
      }
code: protected function filterAndSeparateForeignKeys($foreignKeys, $table)
      {
          $results = ['local' => [], 'remote' => []];
          foreach ($foreignKeys as $foreignKey) {
              if ($foreignKey->TABLE_NAME == $table) {
                  $results['local'][] = $foreignKey;
              }
              if ($foreignKey->REFERENCED_TABLE_NAME == $table) {
                  $results['remote'][] = $foreignKey;
              }
          }
  
          return $results;
      }
code_tokens: protected function filterAndSeparateForeignKeys ( $ foreignKeys , $ table ) { $ results = [ 'local' => [ ] , 'remote' => [ ] ] ; foreach ( $ foreignKeys as $ foreignKey ) { if ( $ foreignKey -> TABLE_NAME == $ table ) { $ results [ 'local' ] [ ] = $ foreignKey ; } if ( $ foreignKey -> REFERENCED_TABLE_NAME == $ table ) { $ results [ 'remote' ] [ ] = $ foreignKey ; } } return $ results ; }
docstring: Only show the keys where table is mentioned.
  
  @param $foreignKeys
  @param $table
  
  @return array
docstring_tokens: Only show the keys where table is mentioned .