Define the routes for the application.

@return void
968928
public function map()
    {
        $appPath = __DIR__ . DIRECTORY_SEPARATOR;
        $path = $appPath . ".." . DIRECTORY_SEPARATOR . ".." . DIRECTORY_SEPARATOR . "routes" . DIRECTORY_SEPARATOR;

        $this->mapApiRoutes($path);

        $this->mapWebRoutes($path);

        //
    }
365843
protected function mapWebRoutes(): void
    {
        $file = $this->basePath.'routes/web.php';

        if (file_exists($file)) {
            $this->loadRoutesFrom(
                Route::middleware('web')
                ->group($file));
        }
    }
130676
private function runController(): void
    {
        //get route information
        $action = $this->routeAction;
        $param = $this->routeParam;

        //action - call controller passing params
        if (!empty($param)) {
            \call_user_func_array([$this->controller, $action], $param);
            return;
        }

        //action - call controller
        if ($action) {
            \call_user_func([$this->controller, $action]);
        }
    }
763927
private function gatherRoutesDefinitions()
    {
        $route = $this->findRouteByName($this->homeRouteName);
        $this->homeDefinition = new RouteDefinition($this->homeRouteName, $this->resolveRouteOptions($route, $this->homeRouteName));

        /** @var Route $route */
        foreach ($this->routes as $name => $route) {
            if ($this->homeRouteName !== $name && null !== $cms = $route->getOption('_cms')) {
                if (array_key_exists('name', $cms)) {
                    $this->createRouteDefinition($name, $route);
                }
            }
        }

        $this->homeDefinition->sortChildren();
    }
371079
public function map() : void
    {
        $this->router->pattern('id', '\d+');
        $this->router->pattern('hash', '[a-z0-9]+');
        $this->router->pattern('uuid', '[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}');
        $this->router->pattern('slug', '[a-z0-9-]+');
        $this->router->pattern('token', '[a-zA-Z0-9]{60}');

        // Allow full domain routing by including dots in the domain regex pattern. Same
        // use-case as subdomains, only this enables you to handle i.e. www.site1.com
        // and www.site2.com within the same Laravel application with a single route or
        // route group.
        $this->router->pattern('domain', '[a-z0-9.]+');
    }
381733
public function mapRoute()
    {
        $this->map('/null/create', 'create')->via('GET', 'POST');
        $this->map('/:id/read', 'read')->via('GET');
        $this->map('/:id/update', 'update')->via('GET', 'POST');
        $this->map('/:id/delete', 'delete')->via('GET', 'POST');

        $this->map('/', 'search')->via('GET');
        $this->map('/', 'create')->via('POST');
        $this->map('/:id', 'read')->via('GET');
        $this->map('/:id', 'update')->via('PUT');
        $this->map('/:id', 'delete')->via('DELETE');

    }
1107647
public function loadRoutes()
    {
        $routeFiles = $this->config["routeFiles"];
        foreach ($routeFiles as $file) {
            $this->loadFile($file, ["app" => $this]);
        }
        return $this;
    }
1131491
private function addCustomRoutes()
    {
        foreach (Route::getRoutes() as $route) {
            $this->_router->respond($route['method'], $route['path'], $route['callback']);
        }
    }
916212
protected function setRouteProperties()
    {
        $this->current_route = $this->route->get();

        $this->path = $this->url->path();
        $this->is_backend = $this->url->isBackend();
        $this->is_install = $this->url->isInstall();

        $this->host = $this->server->httpHost();
        $this->scheme = $this->server->httpScheme();
        $this->uri_path = $this->server->requestUri();
        $this->is_ajax = $this->server->isAjaxRequest();
        $this->uri = $this->scheme . $this->host . $this->uri_path;

        $this->base = $this->request->base();
        $this->query = (array) $this->request->get(null, array(), 'array');
    }
1334981
protected function loadRoutes()
    {
        $this->hook->trigger(self::HOOK_LOAD_ROUTES_BEFORE);
        if ($this->config->get('parable.routes')) {
            foreach ($this->config->get('parable.routes') as $routesClass) {
                $routes = \Parable\DI\Container::create($routesClass);

                if (!($routes instanceof \Parable\Framework\Routing\AbstractRouting)) {
                    throw new \Parable\Framework\Exception(
                        "{$routesClass} does not extend \Parable\Framework\Routing\AbstractRouting"
                    );
                }

                // Load the routes
                $routes->load();
            }
        } else {
            $this->hook->trigger(self::HOOK_LOAD_ROUTES_NO_ROUTES_FOUND);
        }
        $this->hook->trigger(self::HOOK_LOAD_ROUTES_AFTER);
        return $this;
    }
731402
public function Index() {
      $this->Permission('Garden.Settings.Manage');
      $this->AddSideMenu('dashboard/routes');
      $this->AddJsFile('routes.js');
      $this->Title(T('Routes'));
      
      $this->MyRoutes = Gdn::Router()->Routes;
      $this->Render();
   }
853970
protected function defineRoutes()
    {
        $route = $this->app->make('router');

        $route->any('/payment/authorize/{payum_token}', array(
            'as' => 'payum_authorize_do',
            'uses' => 'Payum\LaravelPackage\Controller\AuthorizeController@doAction'
        ));

        $route->any('/payment/capture/{payum_token}', array(
            'as' => 'payum_capture_do',
            'uses' => 'Payum\LaravelPackage\Controller\CaptureController@doAction'
        ));

        $route->any('/payment/refund/{payum_token}', array(
            'as' => 'payum_refund_do',
            'uses' => 'Payum\LaravelPackage\Controller\RefundController@doAction'
        ));

        $route->any('/payment/notify/{payum_token}', array(
            'as' => 'payum_notify_do',
            'uses' => 'Payum\LaravelPackage\Controller\NotifyController@doAction'
        ));

        $route->any('/payment/notify/unsafe/{gateway_name}', array(
            'as' => 'payum_notify_do_unsafe',
            'uses' => 'Payum\LaravelPackage\Controller\NotifyController@doUnsafeAction'
        ));
    }
964931
private function setRoutes()
    {
        foreach($this->myModules as $module) {
            $scModule = snake_case( $module, '-' );
            $subModules = config("{$scModule}.permissions");
            if ( ! is_null($subModules)) {
                foreach($subModules as $sub => $routes) {
                    $hasRoutes = array_filter(array_keys($routes['routes']),function($item)
                    {
                        return hasPermission($item);
                    });
                    if(count($hasRoutes) > 0) {
                        $this->routes[$scModule . '_' . $sub] = $routes;
                    }
                }
            }
        }
    }
255943
protected function registerCustomRoutes()
    {
        if (file_exists($file = $this->getBootstrapPath('routes.php'))) {
            $this->registerRoutes(function (Router $route) use ($file) {
                require $file;
            });
        }
    }
245193
public function generateRoutes()
    {
        $routes = property_exists(app(), 'router')? app()->router->getRoutes() : app()->getRoutes();
        foreach ($routes as $route) {
            array_push($this->routes, [
                'method' => $route['method'],
                'uri' => $route['uri'],
                'name' => $this->getRouteName($route),
                'action' => $this->getRouteAction($route),
                'middleware' => $this->getRouteMiddleware($route),
                'map' => $this->getRouteMapTo($route)
            ]);
        }
    }
767012
protected function mapWebRoutes()
    {
        Route::group([
            'middleware' => config($this->package.'.web_routes_middleware') ?: 'web',
            'namespace'  => $this->namespace,
            'prefix' => $this->prefix,
        ], function ($router) {
            require __DIR__.'/../Routes/web.php';
        });
    }
167300
private function runView(): void
    {
        $action = ($this->routeAction) ? $this->routeAction : 'index';

        \call_user_func([$this->view, $action]);
    }