commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
Loading...
Searching...
No Matches
AssetChangeValueModel.php
1<?php
2
3declare(strict_types=1);
10
15use stdClass;
18
23{
24
25
30 protected $id;
31
36 protected $name;
37
38
42 public function __construct(
43 ?string $id = null,
45 ) {
46 $this->id = $id;
47 $this->name = $name;
48
49 }
50
57 public function getId()
58 {
59 if (is_null($this->id)) {
61 $data = $this->raw(self::FIELD_ID);
62 if (is_null($data)) {
63 return null;
64 }
65 $this->id = (string) $data;
66 }
67
68 return $this->id;
69 }
70
77 public function getName()
78 {
79 if (is_null($this->name)) {
81 $data = $this->raw(self::FIELD_NAME);
82 if (is_null($data)) {
83 return null;
84 }
85
86 $this->name = LocalizedStringModel::of($data);
87 }
88
89 return $this->name;
90 }
91
92
96 public function setId(?string $id): void
97 {
98 $this->id = $id;
99 }
100
104 public function setName(?LocalizedString $name): void
105 {
106 $this->name = $name;
107 }
108
109
110
111}
__construct(?string $id=null, ?LocalizedString $name=null)