| 1 |
<?php |
| 2 |
|
| 3 |
namespace StoreEngine\Classes\Data; |
| 4 |
|
| 5 |
class AttributeData { |
| 6 |
|
| 7 |
public int $term_id; |
| 8 |
public int $term_taxonomy_id; |
| 9 |
public string $name; |
| 10 |
public string $slug; |
| 11 |
public string $description; |
| 12 |
public string $taxonomy; |
| 13 |
public int $count; |
| 14 |
public int $term_order; |
| 15 |
|
| 16 |
public function set_data( object $data ): self { |
| 17 |
$this->term_id = (int) $data->term_id; |
| 18 |
$this->term_taxonomy_id = $data->term_taxonomy_id; |
| 19 |
$this->name = $data->name; |
| 20 |
$this->slug = $data->slug; |
| 21 |
$this->description = $data->description; |
| 22 |
$this->taxonomy = $data->taxonomy; |
| 23 |
$this->count = (int) $data->count; |
| 24 |
$this->term_order = (int) $data->term_order; |
| 25 |
|
| 26 |
return $this; |
| 27 |
} |
| 28 |
|
| 29 |
} |
| 30 |
|