TierPriceInterface.php 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\Catalog\Api\Data;
  7. /**
  8. * Tier price interface.
  9. * @api
  10. * @since 102.0.0
  11. */
  12. interface TierPriceInterface extends \Magento\Framework\Api\ExtensibleDataInterface
  13. {
  14. /**#@+
  15. * Constants
  16. */
  17. const PRICE = 'price';
  18. const PRICE_TYPE = 'price_type';
  19. const WEBSITE_ID = 'website_id';
  20. const SKU = 'sku';
  21. const CUSTOMER_GROUP = 'customer_group';
  22. const QUANTITY = 'quantity';
  23. const PRICE_TYPE_FIXED = 'fixed';
  24. const PRICE_TYPE_DISCOUNT = 'discount';
  25. /**#@-*/
  26. /**
  27. * Set tier price.
  28. *
  29. * @param float $price
  30. * @return $this
  31. * @since 102.0.0
  32. */
  33. public function setPrice($price);
  34. /**
  35. * Get tier price.
  36. *
  37. * @return float
  38. * @since 102.0.0
  39. */
  40. public function getPrice();
  41. /**
  42. * Set tier price type.
  43. *
  44. * @param string $type
  45. * @return $this
  46. * @since 102.0.0
  47. */
  48. public function setPriceType($type);
  49. /**
  50. * Get tier price type.
  51. *
  52. * @return string
  53. * @since 102.0.0
  54. */
  55. public function getPriceType();
  56. /**
  57. * Set website id.
  58. *
  59. * @param int $websiteId
  60. * @return $this
  61. * @since 102.0.0
  62. */
  63. public function setWebsiteId($websiteId);
  64. /**
  65. * Get website id.
  66. *
  67. * @return int
  68. * @since 102.0.0
  69. */
  70. public function getWebsiteId();
  71. /**
  72. * Set SKU.
  73. *
  74. * @param string $sku
  75. * @return $this
  76. * @since 102.0.0
  77. */
  78. public function setSku($sku);
  79. /**
  80. * Get SKU.
  81. *
  82. * @return string
  83. * @since 102.0.0
  84. */
  85. public function getSku();
  86. /**
  87. * Set customer group.
  88. *
  89. * @param string $group
  90. * @return $this
  91. * @since 102.0.0
  92. */
  93. public function setCustomerGroup($group);
  94. /**
  95. * Get customer group.
  96. *
  97. * @return string
  98. * @since 102.0.0
  99. */
  100. public function getCustomerGroup();
  101. /**
  102. * Set quantity.
  103. *
  104. * @param float $quantity
  105. * @return $this
  106. * @since 102.0.0
  107. */
  108. public function setQuantity($quantity);
  109. /**
  110. * Get quantity.
  111. *
  112. * @return float
  113. * @since 102.0.0
  114. */
  115. public function getQuantity();
  116. /**
  117. * Retrieve existing extension attributes object or create a new one.
  118. *
  119. * @return \Magento\Catalog\Api\Data\TierPriceExtensionInterface|null
  120. * @since 102.0.0
  121. */
  122. public function getExtensionAttributes();
  123. /**
  124. * Set an extension attributes object.
  125. *
  126. * @param \Magento\Catalog\Api\Data\TierPriceExtensionInterface $extensionAttributes
  127. * @return $this
  128. * @since 102.0.0
  129. */
  130. public function setExtensionAttributes(
  131. \Magento\Catalog\Api\Data\TierPriceExtensionInterface $extensionAttributes
  132. );
  133. }