CustomerInterface.php 7.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370
  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. namespace Magento\Customer\Api\Data;
  7. /**
  8. * Customer interface.
  9. * @api
  10. * @since 100.0.2
  11. */
  12. interface CustomerInterface extends \Magento\Framework\Api\CustomAttributesDataInterface
  13. {
  14. /**#@+
  15. * Constants defined for keys of the data array. Identical to the name of the getter in snake case
  16. */
  17. const ID = 'id';
  18. const CONFIRMATION = 'confirmation';
  19. const CREATED_AT = 'created_at';
  20. const UPDATED_AT = 'updated_at';
  21. const CREATED_IN = 'created_in';
  22. const DOB = 'dob';
  23. const EMAIL = 'email';
  24. const FIRSTNAME = 'firstname';
  25. const GENDER = 'gender';
  26. const GROUP_ID = 'group_id';
  27. const LASTNAME = 'lastname';
  28. const MIDDLENAME = 'middlename';
  29. const PREFIX = 'prefix';
  30. const STORE_ID = 'store_id';
  31. const SUFFIX = 'suffix';
  32. const TAXVAT = 'taxvat';
  33. const WEBSITE_ID = 'website_id';
  34. const DEFAULT_BILLING = 'default_billing';
  35. const DEFAULT_SHIPPING = 'default_shipping';
  36. const KEY_ADDRESSES = 'addresses';
  37. const DISABLE_AUTO_GROUP_CHANGE = 'disable_auto_group_change';
  38. /**#@-*/
  39. /**
  40. * Get customer id
  41. *
  42. * @return int|null
  43. */
  44. public function getId();
  45. /**
  46. * Set customer id
  47. *
  48. * @param int $id
  49. * @return $this
  50. */
  51. public function setId($id);
  52. /**
  53. * Get group id
  54. *
  55. * @return int|null
  56. */
  57. public function getGroupId();
  58. /**
  59. * Set group id
  60. *
  61. * @param int $groupId
  62. * @return $this
  63. */
  64. public function setGroupId($groupId);
  65. /**
  66. * Get default billing address id
  67. *
  68. * @return string|null
  69. */
  70. public function getDefaultBilling();
  71. /**
  72. * Set default billing address id
  73. *
  74. * @param string $defaultBilling
  75. * @return $this
  76. */
  77. public function setDefaultBilling($defaultBilling);
  78. /**
  79. * Get default shipping address id
  80. *
  81. * @return string|null
  82. */
  83. public function getDefaultShipping();
  84. /**
  85. * Set default shipping address id
  86. *
  87. * @param string $defaultShipping
  88. * @return $this
  89. */
  90. public function setDefaultShipping($defaultShipping);
  91. /**
  92. * Get confirmation
  93. *
  94. * @return string|null
  95. */
  96. public function getConfirmation();
  97. /**
  98. * Set confirmation
  99. *
  100. * @param string $confirmation
  101. * @return $this
  102. */
  103. public function setConfirmation($confirmation);
  104. /**
  105. * Get created at time
  106. *
  107. * @return string|null
  108. */
  109. public function getCreatedAt();
  110. /**
  111. * Set created at time
  112. *
  113. * @param string $createdAt
  114. * @return $this
  115. */
  116. public function setCreatedAt($createdAt);
  117. /**
  118. * Get updated at time
  119. *
  120. * @return string|null
  121. */
  122. public function getUpdatedAt();
  123. /**
  124. * Set updated at time
  125. *
  126. * @param string $updatedAt
  127. * @return $this
  128. */
  129. public function setUpdatedAt($updatedAt);
  130. /**
  131. * Get created in area
  132. *
  133. * @return string|null
  134. */
  135. public function getCreatedIn();
  136. /**
  137. * Set created in area
  138. *
  139. * @param string $createdIn
  140. * @return $this
  141. */
  142. public function setCreatedIn($createdIn);
  143. /**
  144. * Get date of birth
  145. *
  146. * @return string|null
  147. */
  148. public function getDob();
  149. /**
  150. * Set date of birth
  151. *
  152. * @param string $dob
  153. * @return $this
  154. */
  155. public function setDob($dob);
  156. /**
  157. * Get email address
  158. *
  159. * @return string
  160. */
  161. public function getEmail();
  162. /**
  163. * Set email address
  164. *
  165. * @param string $email
  166. * @return $this
  167. */
  168. public function setEmail($email);
  169. /**
  170. * Get first name
  171. *
  172. * @return string
  173. */
  174. public function getFirstname();
  175. /**
  176. * Set first name
  177. *
  178. * @param string $firstname
  179. * @return $this
  180. */
  181. public function setFirstname($firstname);
  182. /**
  183. * Get last name
  184. *
  185. * @return string
  186. */
  187. public function getLastname();
  188. /**
  189. * Set last name
  190. *
  191. * @param string $lastname
  192. * @return $this
  193. */
  194. public function setLastname($lastname);
  195. /**
  196. * Get middle name
  197. *
  198. * @return string|null
  199. */
  200. public function getMiddlename();
  201. /**
  202. * Set middle name
  203. *
  204. * @param string $middlename
  205. * @return $this
  206. */
  207. public function setMiddlename($middlename);
  208. /**
  209. * Get prefix
  210. *
  211. * @return string|null
  212. */
  213. public function getPrefix();
  214. /**
  215. * Set prefix
  216. *
  217. * @param string $prefix
  218. * @return $this
  219. */
  220. public function setPrefix($prefix);
  221. /**
  222. * Get suffix
  223. *
  224. * @return string|null
  225. */
  226. public function getSuffix();
  227. /**
  228. * Set suffix
  229. *
  230. * @param string $suffix
  231. * @return $this
  232. */
  233. public function setSuffix($suffix);
  234. /**
  235. * Get gender
  236. *
  237. * @return int|null
  238. */
  239. public function getGender();
  240. /**
  241. * Set gender
  242. *
  243. * @param int $gender
  244. * @return $this
  245. */
  246. public function setGender($gender);
  247. /**
  248. * Get store id
  249. *
  250. * @return int|null
  251. */
  252. public function getStoreId();
  253. /**
  254. * Set store id
  255. *
  256. * @param int $storeId
  257. * @return $this
  258. */
  259. public function setStoreId($storeId);
  260. /**
  261. * Get tax Vat
  262. *
  263. * @return string|null
  264. */
  265. public function getTaxvat();
  266. /**
  267. * Set tax Vat
  268. *
  269. * @param string $taxvat
  270. * @return $this
  271. */
  272. public function setTaxvat($taxvat);
  273. /**
  274. * Get website id
  275. *
  276. * @return int|null
  277. */
  278. public function getWebsiteId();
  279. /**
  280. * Set website id
  281. *
  282. * @param int $websiteId
  283. * @return $this
  284. */
  285. public function setWebsiteId($websiteId);
  286. /**
  287. * Get customer addresses.
  288. *
  289. * @return \Magento\Customer\Api\Data\AddressInterface[]|null
  290. */
  291. public function getAddresses();
  292. /**
  293. * Set customer addresses.
  294. *
  295. * @param \Magento\Customer\Api\Data\AddressInterface[] $addresses
  296. * @return $this
  297. */
  298. public function setAddresses(array $addresses = null);
  299. /**
  300. * Get disable auto group change flag.
  301. *
  302. * @return int|null
  303. */
  304. public function getDisableAutoGroupChange();
  305. /**
  306. * Set disable auto group change flag.
  307. *
  308. * @param int $disableAutoGroupChange
  309. * @return $this
  310. */
  311. public function setDisableAutoGroupChange($disableAutoGroupChange);
  312. /**
  313. * Retrieve existing extension attributes object or create a new one.
  314. *
  315. * @return \Magento\Customer\Api\Data\CustomerExtensionInterface|null
  316. */
  317. public function getExtensionAttributes();
  318. /**
  319. * Set an extension attributes object.
  320. *
  321. * @param \Magento\Customer\Api\Data\CustomerExtensionInterface $extensionAttributes
  322. * @return $this
  323. */
  324. public function setExtensionAttributes(\Magento\Customer\Api\Data\CustomerExtensionInterface $extensionAttributes);
  325. }