| Total Complexity | 2 |
| Total Lines | 29 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 8 | class UpdatedUsersResponseBuilder { |
||
| 9 | |||
| 10 | /** |
||
| 11 | * @var UserUpdateInformation[] |
||
| 12 | */ |
||
| 13 | private $users = [ ]; |
||
| 14 | |||
| 15 | /** |
||
| 16 | * @param string $username |
||
| 17 | * @param \DateTime $updated |
||
| 18 | * @return UpdatedUsersResponseBuilder |
||
| 19 | */ |
||
| 20 | 1 | public function addUser(string $username, \DateTime $updated): UpdatedUsersResponseBuilder { |
|
| 21 | 1 | $user = new UserUpdateInformation(); |
|
| 22 | 1 | $user->username = $username; |
|
| 23 | 1 | $user->updated = $updated; |
|
| 24 | |||
| 25 | 1 | $this->users[] = $user; |
|
| 26 | 1 | return $this; |
|
| 27 | } |
||
| 28 | |||
| 29 | /** |
||
| 30 | * @return UpdatedUsersResponse |
||
| 31 | */ |
||
| 32 | 1 | public function build(): UpdatedUsersResponse { |
|
| 37 | } |
||
| 38 | } |