original_string: protected static function extract_record($record, $prefix) {
          $result = [];
          $prefixlength = strlen($prefix);
          foreach ($record as $key => $value) {
              if (strpos($key, $prefix) === 0) {
                  $result[substr($key, $prefixlength)] = $value;
              }
          }
          return (object) $result;
      }
code: protected static function extract_record($record, $prefix) {
          $result = [];
          $prefixlength = strlen($prefix);
          foreach ($record as $key => $value) {
              if (strpos($key, $prefix) === 0) {
                  $result[substr($key, $prefixlength)] = $value;
              }
          }
          return (object) $result;
      }
code_tokens: protected static function extract_record ( $ record , $ prefix ) { $ result = [ ] ; $ prefixlength = strlen ( $ prefix ) ; foreach ( $ record as $ key => $ value ) { if ( strpos ( $ key , $ prefix ) === 0 ) { $ result [ substr ( $ key , $ prefixlength ) ] = $ value ; } } return ( object ) $ result ; }
docstring: Extract a record from another one.
  
  @param object $record The record to extract from.
  @param string $prefix The prefix used.
  @return object
docstring_tokens: Extract a record from another one .