src/MyBundle/Entity/UserInfo.php line 10

Open in your IDE?
  1. <?php
  2. namespace MyBundle\Entity;
  3. use TypeError;
  4. /**
  5.  * UserInfo
  6.  */
  7. class UserInfo
  8. {
  9.     /**
  10.      * @var integer
  11.      */
  12.     private $id;
  13.     /**
  14.      * @var integer
  15.      */
  16.     private $driving_exp;
  17.     /**
  18.      * @var integer
  19.      */
  20.     private $family_status;
  21.     /**
  22.      * @var string
  23.      */
  24.     private $city;
  25.     /**
  26.      * @var string
  27.      */
  28.     private $adress;
  29.     /**
  30.      * @var string
  31.      */
  32.     private $build;
  33.     /**
  34.      * @var string
  35.      */
  36.     private $apartment;
  37.     /**
  38.      * @var integer
  39.      */
  40.     private $confirmed_phone;
  41.     /**
  42.      * @var integer
  43.      */
  44.     private $confirm_code;
  45.     /**
  46.      * @var string
  47.      */
  48.     private $hash;
  49.     /**
  50.      * @var string
  51.      */
  52.     private $email_hash;
  53.     /**
  54.      * @var integer
  55.      */
  56.     private $sms_count;
  57.     /**
  58.      * Get id
  59.      *
  60.      * @return integer
  61.      */
  62.     public function getId()
  63.     {
  64.         return $this->id;
  65.     }
  66.     /**
  67.      * Set drivingExp
  68.      *
  69.      * @param integer $drivingExp
  70.      *
  71.      * @return UserInfo
  72.      */
  73.     public function setDrivingExp($drivingExp)
  74.     {
  75.         $this->driving_exp $drivingExp;
  76.         return $this;
  77.     }
  78.     /**
  79.      * Get drivingExp
  80.      *
  81.      * @return integer
  82.      */
  83.     public function getDrivingExp()
  84.     {
  85.         return $this->driving_exp;
  86.     }
  87.     /**
  88.      * Set familyStatus
  89.      *
  90.      * @param integer $familyStatus
  91.      *
  92.      * @return UserInfo
  93.      */
  94.     public function setFamilyStatus($familyStatus)
  95.     {
  96.         $this->family_status $familyStatus;
  97.         return $this;
  98.     }
  99.     /**
  100.      * Get familyStatus
  101.      *
  102.      * @return integer
  103.      */
  104.     public function getFamilyStatus()
  105.     {
  106.         return $this->family_status;
  107.     }
  108.     /**
  109.      * Set city
  110.      *
  111.      * @param string $city
  112.      *
  113.      * @return UserInfo
  114.      */
  115.     public function setCity($city)
  116.     {
  117.         $this->city $city;
  118.         return $this;
  119.     }
  120.     /**
  121.      * Get city
  122.      *
  123.      * @return string
  124.      */
  125.     public function getCity()
  126.     {
  127.         return $this->city;
  128.     }
  129.     /**
  130.      * Set adress
  131.      *
  132.      * @param string $adress
  133.      *
  134.      * @return UserInfo
  135.      */
  136.     public function setAdress($adress)
  137.     {
  138.         $this->adress $adress;
  139.         return $this;
  140.     }
  141.     /**
  142.      * Get adress
  143.      *
  144.      * @return string
  145.      */
  146.     public function getAdress()
  147.     {
  148.         return $this->adress;
  149.     }
  150.     /**
  151.      * Set build
  152.      *
  153.      * @param string $build
  154.      *
  155.      * @return UserInfo
  156.      */
  157.     public function setBuild($build)
  158.     {
  159.         $this->build $build;
  160.         return $this;
  161.     }
  162.     /**
  163.      * Get build
  164.      *
  165.      * @return string
  166.      */
  167.     public function getBuild()
  168.     {
  169.         return $this->build;
  170.     }
  171.     /**
  172.      * Set apartment
  173.      *
  174.      * @param string $apartment
  175.      *
  176.      * @return UserInfo
  177.      */
  178.     public function setApartment($apartment)
  179.     {
  180.         $this->apartment $apartment;
  181.         return $this;
  182.     }
  183.     /**
  184.      * Get apartment
  185.      *
  186.      * @return string
  187.      */
  188.     public function getApartment()
  189.     {
  190.         return $this->apartment;
  191.     }
  192.     /**
  193.      * Set confirmedPhone
  194.      *
  195.      * @param integer $confirmedPhone
  196.      *
  197.      * @return UserInfo
  198.      */
  199.     public function setConfirmedPhone($confirmedPhone)
  200.     {
  201.         $this->confirmed_phone $confirmedPhone;
  202.         return $this;
  203.     }
  204.     /**
  205.      * Get confirmedPhone
  206.      *
  207.      * @return integer
  208.      */
  209.     public function getConfirmedPhone()
  210.     {
  211.         return $this->confirmed_phone;
  212.     }
  213.     /**
  214.      * Set confirmCode
  215.      *
  216.      * @param integer $confirmCode
  217.      *
  218.      * @return UserInfo
  219.      */
  220.     public function setConfirmCode($confirmCode)
  221.     {
  222.         $this->confirm_code $confirmCode;
  223.         return $this;
  224.     }
  225.     /**
  226.      * Get confirmCode
  227.      *
  228.      * @return integer
  229.      */
  230.     public function getConfirmCode()
  231.     {
  232.         return $this->confirm_code;
  233.     }
  234.     /**
  235.      * Set hash
  236.      *
  237.      * @param string $hash
  238.      *
  239.      * @return UserInfo
  240.      */
  241.     public function setHash($hash)
  242.     {
  243.         $this->hash $hash;
  244.         return $this;
  245.     }
  246.     /**
  247.      * Get hash
  248.      *
  249.      * @return string
  250.      */
  251.     public function getHash()
  252.     {
  253.         return $this->hash;
  254.     }
  255.     /**
  256.      * Set emailHash
  257.      *
  258.      * @param string $emailHash
  259.      *
  260.      * @return UserInfo
  261.      */
  262.     public function setEmailHash($emailHash)
  263.     {
  264.         $this->email_hash $emailHash;
  265.         return $this;
  266.     }
  267.     /**
  268.      * Get emailHash
  269.      *
  270.      * @return string
  271.      */
  272.     public function getEmailHash()
  273.     {
  274.         return $this->email_hash;
  275.     }
  276.     /**
  277.      * Set smsCount
  278.      *
  279.      * @param integer $smsCount
  280.      *
  281.      * @return UserInfo
  282.      */
  283.     public function setSmsCount($smsCount)
  284.     {
  285.         $this->sms_count $smsCount;
  286.         return $this;
  287.     }
  288.     /**
  289.      * Get smsCount
  290.      *
  291.      * @return integer
  292.      */
  293.     public function getSmsCount()
  294.     {
  295.         return $this->sms_count;
  296.     }
  297.     /**
  298.      * @var array
  299.      */
  300.     private $phones;
  301.     /**
  302.      * Set phones
  303.      *
  304.      * @param array $phones
  305.      *
  306.      * @return UserInfo
  307.      */
  308.     public function setPhones($phones)
  309.     {
  310.         if (is_array($phones)) {
  311.             $this->phones json_encode($phones);
  312.         } else {
  313.             throw new TypeError('Type is not array');
  314.         }
  315.         return $this;
  316.     }
  317.     /**
  318.      * Get phones
  319.      *
  320.      * @return array
  321.      */
  322.     public function getPhones()
  323.     {
  324.         if (is_string($this->phones)) {
  325.             return json_decode($this->phones);
  326.         }
  327.         return $this->phones;
  328.     }
  329. }