class MigrateMessageCapture in Drupal 8
Same name and namespace in other branches
- 9 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
Allows capturing messages rather than displaying them directly.
Hierarchy
- class \Drupal\migrate_drupal_ui\Batch\MigrateMessageCapture implements 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
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
MigrateMessageCapture:: |
protected | property | Array of recorded messages. | |
MigrateMessageCapture:: |
public | function | Clears out any captured messages. | |
MigrateMessageCapture:: |
public | function |
Displays a migrate message. Overrides MigrateMessageInterface:: |
|
MigrateMessageCapture:: |
public | function | Returns any captured messages. |