PdfEngine.php in Entity Print 8
File
src/Entity/PdfEngine.php
View source
<?php
namespace Drupal\entity_print\Entity;
use Drupal\Core\Config\Entity\ConfigEntityBase;
use Drupal\Core\Plugin\DefaultSingleLazyPluginCollection;
class PdfEngine extends ConfigEntityBase implements PdfEngineInterface {
protected $pdfEnginePluginCollection;
protected $settings = [];
protected $id;
public function getSettings() {
return $this->settings;
}
public function setSettings(array $settings) {
$this->settings = $settings;
return $this;
}
public function getPdfEnginePluginCollection() {
if (!$this->pdfEnginePluginCollection) {
$this->pdfEnginePluginCollection = new DefaultSingleLazyPluginCollection($this
->getPdfEnginePluginManager(), $this->id, $this->settings);
}
return $this->pdfEnginePluginCollection;
}
public function getPluginCollections() {
return [
'settings' => $this
->getPdfEnginePluginCollection(),
];
}
protected function getPdfEnginePluginManager() {
return \Drupal::service('plugin.manager.entity_print.pdf_engine');
}
}
Classes
Name |
Description |
PdfEngine |
Defines the Pdf Engine specific configuration. |