protected function FeedsProcessor::clean in Feeds 7.2
Deletes entities which were not found during processing.
@todo batch delete?
Parameters
FeedsState $state: The FeedsState object for the given stage.
3 calls to FeedsProcessor::clean()
- FeedsNodeProcessor::clean in plugins/
FeedsNodeProcessor.inc - Overrides FeedsProcessor::clean().
- FeedsProcessor::process in plugins/
FeedsProcessor.inc - Process the result of the parsing stage.
- FeedsUserProcessor::clean in plugins/
FeedsUserProcessor.inc - Overrides FeedsProcessor::clean().
2 methods override FeedsProcessor::clean()
- FeedsNodeProcessor::clean in plugins/
FeedsNodeProcessor.inc - Overrides FeedsProcessor::clean().
- FeedsUserProcessor::clean in plugins/
FeedsUserProcessor.inc - Overrides FeedsProcessor::clean().
File
- plugins/
FeedsProcessor.inc, line 616 - Contains FeedsProcessor and related classes.
Class
- FeedsProcessor
- Abstract class, defines interface for processors.
Code
protected function clean(FeedsState $state) {
// We clean only if needed.
if ($this->config['update_non_existent'] != FEEDS_DELETE_NON_EXISTENT) {
return;
}
if ($total = count($state->removeList)) {
$this
->entityDeleteMultiple($state->removeList);
$state->deleted += $total;
}
}