You are here

protected function MigrateItemsXML::getItemID in Migrate 7.2

Same name and namespace in other branches
  1. 6.2 plugins/sources/xml.inc \MigrateItemsXML::getItemID()

Get the item ID from the itemXML based on itemIDXpath.

Parameters

SimpleXMLElement $item_xml: Element from we get the ID

Return value

string The item ID

2 calls to MigrateItemsXML::getItemID()
MigrateItemsXML::getIDsFromXML in plugins/sources/xml.inc
Given an XML object, parse out the IDs for processing and return them as an array. The location of the IDs in the XML are based on the item xpath and item ID xpath set in the constructor. eg, xpath = itemXpath . '/' . itemIDXpath IDs are…
MigrateItemsXML::getItemsFromXML in plugins/sources/xml.inc
Parses out the items from a given XML object, and parse it's items.

File

plugins/sources/xml.inc, line 771
Support for migration from XML sources.

Class

MigrateItemsXML
Implementation of MigrateItems, for providing a list of IDs and for retrieving a parsed XML document given an ID from this list.

Code

protected function getItemID($item_xml) {
  return $this
    ->getElementValue($item_xml, $this->itemIDXpath);
}