123456789101112131415161718192021222324252627282930313233343536373839 |
- <?php
- /**
- * Copyright © Magento, Inc. All rights reserved.
- * See COPYING.txt for license details.
- */
- namespace Magento\Signifyd\Model;
- use Magento\Framework\DataObject\IdentityGeneratorInterface;
- /**
- * Encapsulates generation of uuid by quote id.
- */
- class SignifydOrderSessionId
- {
- /**
- * @var IdentityGeneratorInterface
- */
- private $identityGenerator;
- /**
- * @param IdentityGeneratorInterface $identityGenerator
- */
- public function __construct(
- IdentityGeneratorInterface $identityGenerator
- ) {
- $this->identityGenerator = $identityGenerator;
- }
- /**
- * Returns unique identifier through generation uuid by quote id.
- *
- * @param int $quoteId
- * @return string
- */
- public function get($quoteId)
- {
- return $this->identityGenerator->generateIdForData($quoteId);
- }
- }
|