AttributeGroupRepositoryInterface.php 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. <?php
  2. /**
  3. *
  4. * Copyright © Magento, Inc. All rights reserved.
  5. * See COPYING.txt for license details.
  6. */
  7. namespace Magento\Eav\Api;
  8. /**
  9. * Interface AttributeGroupRepositoryInterface
  10. * @api
  11. * @since 100.0.2
  12. */
  13. interface AttributeGroupRepositoryInterface
  14. {
  15. /**
  16. * Save attribute group
  17. *
  18. * @param \Magento\Eav\Api\Data\AttributeGroupInterface $group
  19. * @return \Magento\Eav\Api\Data\AttributeGroupInterface
  20. * @throws \Magento\Framework\Exception\NoSuchEntityException
  21. * @throws \Magento\Framework\Exception\StateException
  22. */
  23. public function save(\Magento\Eav\Api\Data\AttributeGroupInterface $group);
  24. /**
  25. * Retrieve attribute group
  26. *
  27. * @param int $groupId
  28. * @return \Magento\Eav\Api\Data\AttributeGroupInterface
  29. * @throws \Magento\Framework\Exception\NoSuchEntityException
  30. */
  31. public function get($groupId);
  32. /**
  33. * Retrieve list of attribute groups
  34. *
  35. * @param \Magento\Framework\Api\SearchCriteriaInterface $searchCriteria
  36. * @return \Magento\Eav\Api\Data\AttributeGroupSearchResultsInterface
  37. * @throws \Magento\Framework\Exception\NoSuchEntityException
  38. */
  39. public function getList(\Magento\Framework\Api\SearchCriteriaInterface $searchCriteria);
  40. /**
  41. * Remove attribute group by id
  42. *
  43. * @param int $groupId
  44. * @return bool
  45. * @throws \Magento\Framework\Exception\NoSuchEntityException
  46. * @throws \Magento\Framework\Exception\StateException
  47. */
  48. public function deleteById($groupId);
  49. /**
  50. * Remove attribute group
  51. *
  52. * @param \Magento\Eav\Api\Data\AttributeGroupInterface $group
  53. * @return bool
  54. * @throws \Magento\Framework\Exception\NoSuchEntityException
  55. * @throws \Magento\Framework\Exception\StateException
  56. */
  57. public function delete(\Magento\Eav\Api\Data\AttributeGroupInterface $group);
  58. }