Lock.php 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\Framework\MessageQueue;
  7. /**
  8. * Class Lock to handle message lock transactions.
  9. */
  10. class Lock extends \Magento\Framework\DataObject implements LockInterface
  11. {
  12. /**
  13. * @inheritDoc
  14. */
  15. public function getId()
  16. {
  17. return $this->getData('id');
  18. }
  19. /**
  20. * @inheritDoc
  21. */
  22. public function setId($value)
  23. {
  24. $this->setData('id', $value);
  25. }
  26. /**
  27. * @inheritDoc
  28. */
  29. public function getMessageCode()
  30. {
  31. return $this->getData('message_code');
  32. }
  33. /**
  34. * @inheritDoc
  35. */
  36. public function setMessageCode($value)
  37. {
  38. $this->setData('message_code', $value);
  39. }
  40. /**
  41. * @inheritDoc
  42. */
  43. public function getCreatedAt()
  44. {
  45. return $this->getData('created_at');
  46. }
  47. /**
  48. * @inheritDoc
  49. */
  50. public function setCreatedAt($value)
  51. {
  52. $this->setData('created_at', $value);
  53. }
  54. }