original_string: public static function fromSruRecord(SruRecord $record, Client $client = null)
      {
          $record->data->registerXPathNamespace('marc', 'http://www.loc.gov/MARC21/slim');
          $mmsId = $record->data->text('.//marc:controlfield[@tag="001"]');
  
          return (new self($client, $mmsId))
              ->setMarcRecord($record->data->asXML());
      }
code: public static function fromSruRecord(SruRecord $record, Client $client = null)
      {
          $record->data->registerXPathNamespace('marc', 'http://www.loc.gov/MARC21/slim');
          $mmsId = $record->data->text('.//marc:controlfield[@tag="001"]');
  
          return (new self($client, $mmsId))
              ->setMarcRecord($record->data->asXML());
      }
code_tokens: public static function fromSruRecord ( SruRecord $ record , Client $ client = null ) { $ record -> data -> registerXPathNamespace ( 'marc' , 'http://www.loc.gov/MARC21/slim' ) ; $ mmsId = $ record -> data -> text ( './/marc:controlfield[@tag="001"]' ) ; return ( new self ( $ client , $ mmsId ) ) -> setMarcRecord ( $ record -> data -> asXML ( ) ) ; }
docstring: Initialize from SRU record without having to fetch the Bib record.
  
  @param SruRecord   $record
  @param Client|null $client
  
  @return Bib
docstring_tokens: Initialize from SRU record without having to fetch the Bib record .