Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
MessageIdGenerator.php
Go to the documentation of this file.
1 <?php
7 
12 {
16  private $encryptor;
17 
23  public function __construct(
24  \Magento\Framework\Encryption\EncryptorInterface $encryptor
25  ) {
26  $this->encryptor = $encryptor;
27  }
28 
32  public function generate($topicName)
33  {
34  return $this->encryptor->hash(uniqid($topicName));
35  }
36 }
__construct(\Magento\Framework\Encryption\EncryptorInterface $encryptor)