| Total Complexity | 2 |
| Total Lines | 47 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 30 | class InventoryChangedRequestEntity extends RequestEntity |
||
| 31 | { |
||
| 32 | const UNDERSCORE_ON_SERIALIZATION = false; |
||
| 33 | |||
| 34 | /** |
||
| 35 | * Subscription external id. |
||
| 36 | * Required for all requests. |
||
| 37 | * |
||
| 38 | * @var string |
||
| 39 | */ |
||
| 40 | protected $externalId; |
||
| 41 | |||
| 42 | /** |
||
| 43 | * Target product SKU |
||
| 44 | * |
||
| 45 | * @var string |
||
| 46 | */ |
||
| 47 | protected $sku; |
||
| 48 | |||
| 49 | /** |
||
| 50 | * Unsigned diff between previous and current states. |
||
| 51 | * Addition or subtraction is indicated by endpoint this entity sent to. |
||
| 52 | * |
||
| 53 | * @var int |
||
| 54 | */ |
||
| 55 | protected $quantity; |
||
| 56 | |||
| 57 | /** |
||
| 58 | * @param string $sku |
||
| 59 | * @return static |
||
| 60 | */ |
||
| 61 | public function setSku($sku) |
||
| 62 | { |
||
| 63 | $this->sku = (string) $sku; |
||
| 64 | |||
| 65 | return $this; |
||
| 66 | } |
||
| 67 | |||
| 68 | /** |
||
| 69 | * @return array |
||
| 70 | */ |
||
| 71 | public function getRequired() |
||
| 77 | ); |
||
| 78 | } |
||
| 80 |