You are here

public function DiffEntityComparison::__construct in Diff 8

Constructs a DiffEntityComparison object.

Parameters

\Drupal\Core\Config\ConfigFactory $config_factory: The configuration factory.

\Drupal\diff\DiffFormatter $diff_formatter: The diff formatter service.

\Drupal\Component\Plugin\PluginManagerInterface $plugin_manager: The plugin manager service.

\Drupal\diff\DiffEntityParser $entity_parser: The entity parser.

\Drupal\diff\DiffBuilderManager $diff_builder_manager: The diff builder manager.

File

src/DiffEntityComparison.php, line 81

Class

DiffEntityComparison
Entity comparison service that prepares a diff of a pair of entities.

Namespace

Drupal\diff

Code

public function __construct(ConfigFactory $config_factory, DiffFormatter $diff_formatter, PluginManagerInterface $plugin_manager, DiffEntityParser $entity_parser, DiffBuilderManager $diff_builder_manager) {
  $this->configFactory = $config_factory;
  $this->pluginsConfig = $this->configFactory
    ->get('diff.plugins');
  $this->diffFormatter = $diff_formatter;
  $this->fieldTypeDefinitions = $plugin_manager
    ->getDefinitions();
  $this->entityParser = $entity_parser;
  $this->diffBuilderManager = $diff_builder_manager;
}