_session = \Config\Services::session(); } abstract public function getAuthButton(); abstract public function execute(): UserEntity; final protected function getUserModel(): UserModel { if (is_null($this->_userModel)) { $this->_userModel = new UserModel(); } return $this->_userModel; } final protected function getUserSNSModel(): SNSUSerModel { if (is_null($this->_snsUserModel)) { $this->_snsUserModel = new SNSUserModel(); } return $this->_snsUserModel; } protected function setSession_process(UserEntity $entity): UserEntity { $this->_session->set(SESSION_NAMES['ISLOGIN'], true); $this->_session->set(SESSION_NAMES['AUTH'], [ 'uid' => $entity->getPK(), 'name' => $entity->getTitle(), 'role' => $entity->role ]); return $entity; } }