eZ\Publish\Core\Persistence\Legacy\Content\UrlAlias\Gateway::historizeBeforeSwap PHP Method

historizeBeforeSwap() abstract public method

Used when swapping Location aliases, this ensures that given $languageMask matches a single entry (database row).
abstract public historizeBeforeSwap ( string $action, integer $languageMask ) : mixed
$action string
$languageMask integer
return mixed
    public abstract function historizeBeforeSwap($action, $languageMask);

Usage Example

Beispiel #1
0
 /**
  * Historizes given existing active entries for two swapped Locations.
  *
  * This should be done before republishing URL aliases, in order to avoid unnecessary
  * conflicts when swapped Locations are siblings.
  *
  * We need to historize everything separately per language (mask), in case the entries
  * remain history future publishing reusages need to be able to take them over cleanly.
  *
  * @see \eZ\Publish\Core\Persistence\Legacy\Content\UrlAlias\Handler::locationSwapped()
  *
  * @param array $location1Entries
  * @param array $location2Entries
  */
 private function historizeBeforeSwap($location1Entries, $location2Entries)
 {
     foreach ($location1Entries as $row) {
         $this->gateway->historizeBeforeSwap($row['action'], $row['lang_mask']);
     }
     foreach ($location2Entries as $row) {
         $this->gateway->historizeBeforeSwap($row['action'], $row['lang_mask']);
     }
 }
All Usage Examples Of eZ\Publish\Core\Persistence\Legacy\Content\UrlAlias\Gateway::historizeBeforeSwap