Advertisement
Guest User

Untitled

a guest
Jun 26th, 2019
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.92 KB | None | 0 0
  1. <?php
  2.  
  3. class MyDTO
  4. {
  5.     /**
  6.      * @var string Первый параметр
  7.      */
  8.     private $firstOption;
  9.  
  10.     /**
  11.      * @var int Это второй параметр
  12.      */
  13.     private $secondOption;
  14.  
  15.     /**
  16.      * @return string
  17.      */
  18.     public function getFirstOption(): string
  19.     {
  20.         return $this->firstOption;
  21.     }
  22.  
  23.     /**
  24.      * @param string $firstOption
  25.      * @return MyDTO
  26.      */
  27.     public function setFirstOption(string $firstOption): MyDTO
  28.     {
  29.         $this->firstOption = $firstOption;
  30.         return $this;
  31.     }
  32.  
  33.     /**
  34.      * @return int
  35.      */
  36.     public function getSecondOption(): int
  37.     {
  38.         return $this->secondOption;
  39.     }
  40.  
  41.     /**
  42.      * @param int $secondOption
  43.      * @return MyDTO
  44.      */
  45.     public function setSecondOption(int $secondOption): MyDTO
  46.     {
  47.         $this->secondOption = $secondOption;
  48.         return $this;
  49.     }
  50. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement