class MigrateMessageCapture
Same name in other branches
- 8.9.x core/modules/migrate_drupal_ui/src/Batch/MigrateMessageCapture.php \Drupal\migrate_drupal_ui\Batch\MigrateMessageCapture
- 10 core/modules/migrate_drupal_ui/src/Batch/MigrateMessageCapture.php \Drupal\migrate_drupal_ui\Batch\MigrateMessageCapture
- 11.x core/modules/migrate_drupal_ui/src/Batch/MigrateMessageCapture.php \Drupal\migrate_drupal_ui\Batch\MigrateMessageCapture
Allows capturing messages rather than displaying them directly.
Hierarchy
- class \Drupal\migrate_drupal_ui\Batch\MigrateMessageCapture implements \Drupal\migrate\MigrateMessageInterface
Expanded class hierarchy of MigrateMessageCapture
File
-
core/
modules/ migrate_drupal_ui/ src/ Batch/ MigrateMessageCapture.php, line 10
Namespace
Drupal\migrate_drupal_ui\BatchView source
class MigrateMessageCapture implements MigrateMessageInterface {
/**
* Array of recorded messages.
*
* @var array
*/
protected $messages = [];
/**
* {@inheritdoc}
*/
public function display($message, $type = 'status') {
$this->messages[] = $message;
}
/**
* Clears out any captured messages.
*/
public function clear() {
$this->messages = [];
}
/**
* Returns any captured messages.
*
* @return array
* The captured messages.
*/
public function getMessages() {
return $this->messages;
}
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overriden Title |
---|---|---|---|---|
MigrateMessageCapture::$messages | protected | property | Array of recorded messages. | |
MigrateMessageCapture::clear | public | function | Clears out any captured messages. | |
MigrateMessageCapture::display | public | function | Displays a migrate message. | Overrides MigrateMessageInterface::display |
MigrateMessageCapture::getMessages | public | function | Returns any captured messages. |
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.