interface WebformElementAttachmentInterface in Webform 6.x
Same name and namespace in other branches
- 8.5 src/Plugin/WebformElementAttachmentInterface.php \Drupal\webform\Plugin\WebformElementAttachmentInterface
Defines the interface for webform elements can provide email attachments.
Hierarchy
- interface \Drupal\webform\Plugin\WebformElementAttachmentInterface
Expanded class hierarchy of WebformElementAttachmentInterface
All classes that implement WebformElementAttachmentInterface
5 files declare their use of WebformElementAttachmentInterface
- Webform.php in src/
Entity/ Webform.php - WebformAttachmentBase.php in modules/
webform_attachment/ src/ Plugin/ WebformElement/ WebformAttachmentBase.php - WebformCompositeBase.php in src/
Plugin/ WebformElement/ WebformCompositeBase.php - WebformManagedFileBase.php in src/
Plugin/ WebformElement/ WebformManagedFileBase.php - WebformSubmissionViewBuilder.php in src/
WebformSubmissionViewBuilder.php
File
- src/
Plugin/ WebformElementAttachmentInterface.php, line 10
Namespace
Drupal\webform\PluginView source
interface WebformElementAttachmentInterface {
/**
* Get files as email attachments.
*
* This is also used to export attachments.
*
* @param array $element
* An element.
* @param \Drupal\webform\WebformSubmissionInterface $webform_submission
* A webform submission.
* @param array $options
* An array of options.
*
* @return array
* An array containing email attachments which include an attachments
* 'filename', 'filemime', 'filepath', and 'filecontent'.
*
* @see \Drupal\webform\Plugin\WebformHandler\EmailWebformHandler::getMessageAttachments
* @see \Drupal\mimemail\Utility\MimeMailFormatHelper::mimeMailHtmlBody
* @see \Drupal\smtp\Plugin\Mail\SMTPMailSystem::mail
* @see \Drupal\swiftmailer\Plugin\Mail\SwiftMailer::attachAsMimeMail
*/
public function getEmailAttachments(array $element, WebformSubmissionInterface $webform_submission, array $options = []);
/**
* Get files as export attachments.
*
* This is also used to export attachments.
*
* @param array $element
* An element.
* @param \Drupal\webform\WebformSubmissionInterface $webform_submission
* A webform submission.
* @param array $options
* An array of options.
*
* @return array
* An array containing email attachments which include an attachments
* 'filename', 'filemime', 'filepath', and 'filecontent'.
*
* @see \Drupal\webform\WebformSubmissionExporter::writeRecords
*/
public function getExportAttachments(array $element, WebformSubmissionInterface $webform_submission, array $options = []);
/**
* Determine if the element type has export attachments.
*
* @return boolearn
* TRUE if the element type has export attachments.
*/
public function hasExportAttachments();
/**
* Get attachment export batch limit.
*
* @return int|NULL
* Batch limit or NULL if the batch limit should not be overidden.
*/
public function getExportAttachmentsBatchLimit();
}
Members
Name![]() |
Modifiers | Type | Description | Overrides |
---|---|---|---|---|
WebformElementAttachmentInterface:: |
public | function | Get files as email attachments. | 3 |
WebformElementAttachmentInterface:: |
public | function | Get files as export attachments. | 3 |
WebformElementAttachmentInterface:: |
public | function | Get attachment export batch limit. | 3 |
WebformElementAttachmentInterface:: |
public | function | Determine if the element type has export attachments. | 3 |