name = $name; $this->email = $email; $this->address = $address; parent::__construct(); } public static function instance($refresh = false) { return self::instantiate([]); } public static function instantiate($row) { return (new \ReflectionClass(static::className()))->newInstanceWithoutConstructor(); } public function getProfile() { return $this->hasOne(ProfileWithConstructor::className(), ['id' => 'profile_id']); } }