Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- class MyDTO
- {
- /**
- * @var string Первый параметр
- */
- private $firstOption;
- /**
- * @var int Это второй параметр
- */
- private $secondOption;
- /**
- * MyDTO constructor.
- * @param string $firstOption
- * @param int $secondOption
- */
- public function __construct(string $firstOption, int $secondOption)
- {
- $this->firstOption = $firstOption;
- $this->secondOption = $secondOption;
- }
- /**
- * @return string
- */
- public function getFirstOption(): string
- {
- return $this->firstOption;
- }
- /**
- * @return int
- */
- public function getSecondOption(): int
- {
- return $this->secondOption;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement