public function Lingotek::getIntelligenceMetadata in Lingotek Translation 3.6.x
Same name and namespace in other branches
- 8.2 src/Lingotek.php \Drupal\lingotek\Lingotek::getIntelligenceMetadata()
- 4.0.x src/Lingotek.php \Drupal\lingotek\Lingotek::getIntelligenceMetadata()
- 3.0.x src/Lingotek.php \Drupal\lingotek\Lingotek::getIntelligenceMetadata()
- 3.1.x src/Lingotek.php \Drupal\lingotek\Lingotek::getIntelligenceMetadata()
- 3.2.x src/Lingotek.php \Drupal\lingotek\Lingotek::getIntelligenceMetadata()
- 3.3.x src/Lingotek.php \Drupal\lingotek\Lingotek::getIntelligenceMetadata()
- 3.4.x src/Lingotek.php \Drupal\lingotek\Lingotek::getIntelligenceMetadata()
- 3.5.x src/Lingotek.php \Drupal\lingotek\Lingotek::getIntelligenceMetadata()
- 3.7.x src/Lingotek.php \Drupal\lingotek\Lingotek::getIntelligenceMetadata()
- 3.8.x src/Lingotek.php \Drupal\lingotek\Lingotek::getIntelligenceMetadata()
Pulls the Intelligence Metadata from the Lingotek Metadata and returns it.
Parameters
array $data: The structure of a document content.
Return value
array
2 calls to Lingotek::getIntelligenceMetadata()
- Lingotek::updateDocument in src/
Lingotek.php - Updates a document in the Lingotek service.
- Lingotek::uploadDocument in src/
Lingotek.php - Uploads a document to the Lingotek service.
File
- src/
Lingotek.php, line 496
Class
- Lingotek
- The connecting class between Drupal and Lingotek
Namespace
Drupal\lingotekCode
public function getIntelligenceMetadata(&$data) {
$metadata = [];
if (is_array($data) && isset($data['_lingotek_metadata']['_intelligence'])) {
$metadata = $data['_lingotek_metadata']['_intelligence'];
unset($data['_lingotek_metadata']['_intelligence']);
}
return $metadata;
}