Illuminate\Routing\Redirector::getUrlGenerator PHP Méthode

getUrlGenerator() public méthode

Get the URL generator instance.
public getUrlGenerator ( ) : UrlGenerator
Résultat UrlGenerator
    public function getUrlGenerator()
    {
        return $this->generator;
    }

Usage Example

 /**
  * Get the URL to redirect to on a validation error.
  *
  * @return string
  */
 protected function getRedirectUrl()
 {
     $url = $this->redirector->getUrlGenerator();
     if ($this->redirect) {
         return $url->to($this->redirect);
     } elseif ($this->redirectRoute) {
         return $url->route($this->redirectRoute);
     } elseif ($this->redirectAction) {
         return $url->action($this->redirectAction);
     }
     return $url->previous();
 }
All Usage Examples Of Illuminate\Routing\Redirector::getUrlGenerator