commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
Loading...
Searching...
No Matches
TooManyRequestsErrorBuilder.php
1<?php
2
3declare(strict_types=1);
10
16use stdClass;
19
24{
29 private $code;
30
35 private $message;
36
43 public function getCode()
44 {
45 return $this->code;
46 }
47
54 public function getMessage()
55 {
56 return $this->message;
57 }
58
63 public function withCode(?string $code)
64 {
65 $this->code = $code;
66
67 return $this;
68 }
69
74 public function withMessage(?string $message)
75 {
76 $this->message = $message;
77
78 return $this;
79 }
80
81
82 public function build(): TooManyRequestsError
83 {
85 $this->code,
86 $this->message
87 );
88 }
89
90 public static function of(): TooManyRequestsErrorBuilder
91 {
92 return new self();
93 }
94}