Condition.php 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\CatalogRule\Model\Data;
  7. use Magento\Framework\Model\AbstractExtensibleModel;
  8. /**
  9. * Class Condition
  10. * @codeCoverageIgnore
  11. */
  12. class Condition extends AbstractExtensibleModel implements \Magento\CatalogRule\Api\Data\ConditionInterface
  13. {
  14. /**
  15. * {@inheritdoc}
  16. */
  17. public function setType($type)
  18. {
  19. return $this->setData(self::TYPE, $type);
  20. }
  21. /**
  22. * {@inheritdoc}
  23. */
  24. public function getType()
  25. {
  26. return $this->getData(self::TYPE);
  27. }
  28. /**
  29. * {@inheritdoc}
  30. */
  31. public function setAttribute($attribute)
  32. {
  33. return $this->setData(self::ATTRIBUTE, $attribute);
  34. }
  35. /**
  36. * {@inheritdoc}
  37. */
  38. public function getAttribute()
  39. {
  40. return $this->getData(self::ATTRIBUTE);
  41. }
  42. /**
  43. * {@inheritdoc}
  44. */
  45. public function setOperator($operator)
  46. {
  47. return $this->setData(self::OPERATOR, $operator);
  48. }
  49. /**
  50. * {@inheritdoc}
  51. */
  52. public function getOperator()
  53. {
  54. return $this->getData(self::OPERATOR);
  55. }
  56. /**
  57. * {@inheritdoc}
  58. */
  59. public function setValue($value)
  60. {
  61. return $this->setData(self::VALUE, $value);
  62. }
  63. /**
  64. * {@inheritdoc}
  65. */
  66. public function getValue()
  67. {
  68. return $this->getData(self::VALUE);
  69. }
  70. /**
  71. * {@inheritdoc}
  72. */
  73. public function setIsValueParsed($isValueParsed)
  74. {
  75. return $this->setData(self::IS_VALUE_PARSED, $isValueParsed);
  76. }
  77. /**
  78. * {@inheritdoc}
  79. */
  80. public function getIsValueParsed()
  81. {
  82. return $this->getData(self::IS_VALUE_PARSED);
  83. }
  84. /**
  85. * {@inheritdoc}
  86. */
  87. public function setAggregator($aggregator)
  88. {
  89. return $this->setData(self::AGGREGATOR, $aggregator);
  90. }
  91. /**
  92. * {@inheritdoc}
  93. */
  94. public function getAggregator()
  95. {
  96. return $this->getData(self::AGGREGATOR);
  97. }
  98. /**
  99. * {@inheritdoc}
  100. */
  101. public function setConditions($conditions)
  102. {
  103. return $this->setData(self::CONDITIONS, $conditions);
  104. }
  105. /**
  106. * {@inheritdoc}
  107. */
  108. public function getConditions()
  109. {
  110. return $this->getData(self::CONDITIONS);
  111. }
  112. /**
  113. * {@inheritdoc}
  114. */
  115. public function getExtensionAttributes()
  116. {
  117. return $this->_getExtensionAttributes();
  118. }
  119. /**
  120. * {@inheritdoc}
  121. */
  122. public function setExtensionAttributes(
  123. \Magento\CatalogRule\Api\Data\ConditionExtensionInterface $extensionAttributes
  124. ) {
  125. return $this->_setExtensionAttributes($extensionAttributes);
  126. }
  127. }