commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
MyCustomerResetPasswordModel.php
1 <?php
2 
3 declare(strict_types=1);
10 
15 use stdClass;
16 
21 {
26  protected $tokenValue;
27 
32  protected $newPassword;
33 
34 
38  public function __construct(
39  ?string $tokenValue = null,
40  ?string $newPassword = null
41  ) {
42  $this->tokenValue = $tokenValue;
43  $this->newPassword = $newPassword;
44  }
45 
52  public function getTokenValue()
53  {
54  if (is_null($this->tokenValue)) {
56  $data = $this->raw(self::FIELD_TOKEN_VALUE);
57  if (is_null($data)) {
58  return null;
59  }
60  $this->tokenValue = (string) $data;
61  }
62 
63  return $this->tokenValue;
64  }
65 
72  public function getNewPassword()
73  {
74  if (is_null($this->newPassword)) {
76  $data = $this->raw(self::FIELD_NEW_PASSWORD);
77  if (is_null($data)) {
78  return null;
79  }
80  $this->newPassword = (string) $data;
81  }
82 
83  return $this->newPassword;
84  }
85 
86 
90  public function setTokenValue(?string $tokenValue): void
91  {
92  $this->tokenValue = $tokenValue;
93  }
94 
98  public function setNewPassword(?string $newPassword): void
99  {
100  $this->newPassword = $newPassword;
101  }
102 }
__construct(?string $tokenValue=null, ?string $newPassword=null)