original_string: protected function extractMetaData(ZipArchive $package)
      {
          // Data holders
          $coreProperties = array();
  
          // Read relations and search for core properties
          $relations = simplexml_load_string($package->getFromName("_rels/.rels"));
          foreach ($relations->Relationship as $rel) {
              if ($rel["Type"] == Zend_Search_Lucene_Document_OpenXml::SCHEMA_COREPROPERTIES) {
                  // Found core properties! Read in contents...
                  $contents = simplexml_load_string(
                      $package->getFromName(dirname($rel["Target"]) . "/" . basename($rel["Target"]))
                  );
  
                  foreach ($contents->children(Zend_Search_Lucene_Document_OpenXml::SCHEMA_DUBLINCORE) as $child) {
                      $coreProperties[$child->getName()] = (string)$child;
                  }
                  foreach ($contents->children(Zend_Search_Lucene_Document_OpenXml::SCHEMA_COREPROPERTIES) as $child) {
                      $coreProperties[$child->getName()] = (string)$child;
                  }
                  foreach ($contents->children(Zend_Search_Lucene_Document_OpenXml::SCHEMA_DUBLINCORETERMS) as $child) {
                      $coreProperties[$child->getName()] = (string)$child;
                  }
              }
          }
  
          return $coreProperties;
      }
code: protected function extractMetaData(ZipArchive $package)
      {
          // Data holders
          $coreProperties = array();
  
          // Read relations and search for core properties
          $relations = simplexml_load_string($package->getFromName("_rels/.rels"));
          foreach ($relations->Relationship as $rel) {
              if ($rel["Type"] == Zend_Search_Lucene_Document_OpenXml::SCHEMA_COREPROPERTIES) {
                  // Found core properties! Read in contents...
                  $contents = simplexml_load_string(
                      $package->getFromName(dirname($rel["Target"]) . "/" . basename($rel["Target"]))
                  );
  
                  foreach ($contents->children(Zend_Search_Lucene_Document_OpenXml::SCHEMA_DUBLINCORE) as $child) {
                      $coreProperties[$child->getName()] = (string)$child;
                  }
                  foreach ($contents->children(Zend_Search_Lucene_Document_OpenXml::SCHEMA_COREPROPERTIES) as $child) {
                      $coreProperties[$child->getName()] = (string)$child;
                  }
                  foreach ($contents->children(Zend_Search_Lucene_Document_OpenXml::SCHEMA_DUBLINCORETERMS) as $child) {
                      $coreProperties[$child->getName()] = (string)$child;
                  }
              }
          }
  
          return $coreProperties;
      }
code_tokens: protected function extractMetaData ( ZipArchive $ package ) { // Data holders $ coreProperties = array ( ) ; // Read relations and search for core properties $ relations = simplexml_load_string ( $ package -> getFromName ( "_rels/.rels" ) ) ; foreach ( $ relations -> Relationship as $ rel ) { if ( $ rel [ "Type" ] == Zend_Search_Lucene_Document_OpenXml :: SCHEMA_COREPROPERTIES ) { // Found core properties! Read in contents... $ contents = simplexml_load_string ( $ package -> getFromName ( dirname ( $ rel [ "Target" ] ) . "/" . basename ( $ rel [ "Target" ] ) ) ) ; foreach ( $ contents -> children ( Zend_Search_Lucene_Document_OpenXml :: SCHEMA_DUBLINCORE ) as $ child ) { $ coreProperties [ $ child -> getName ( ) ] = ( string ) $ child ; } foreach ( $ contents -> children ( Zend_Search_Lucene_Document_OpenXml :: SCHEMA_COREPROPERTIES ) as $ child ) { $ coreProperties [ $ child -> getName ( ) ] = ( string ) $ child ; } foreach ( $ contents -> children ( Zend_Search_Lucene_Document_OpenXml :: SCHEMA_DUBLINCORETERMS ) as $ child ) { $ coreProperties [ $ child -> getName ( ) ] = ( string ) $ child ; } } } return $ coreProperties ; }
docstring: Extract metadata from document
  
  @param  ZipArchive $package ZipArchive OpenXML package
  @return array    Key-value pairs containing document meta data
docstring_tokens: Extract metadata from document