commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
Loading...
Searching...
No Matches
NumberSetAttributeBuilder.php
1<?php
2
3declare(strict_types=1);
10
16use stdClass;
17
21final class NumberSetAttributeBuilder implements Builder
22{
27 private $name;
28
33 private $value;
34
43 public function getName()
44 {
45 return $this->name;
46 }
47
55 public function getValue()
56 {
57 return $this->value;
58 }
59
64 public function withName(?string $name)
65 {
66 $this->name = $name;
67
68 return $this;
69 }
70
75 public function withValue(?array $value)
76 {
77 $this->value = $value;
78
79 return $this;
80 }
81
82
83 public function build(): NumberSetAttribute
84 {
85 return new NumberSetAttributeModel(
86 $this->name,
87 $this->value
88 );
89 }
90
91 public static function of(): NumberSetAttributeBuilder
92 {
93 return new self();
94 }
95}