qtil
advanced-security/qtil-ruby 0.0.2
Search

Class ActionDispatch::Routing::RouteBlock

A block that defines some routes. Route blocks can contribute to the path or controller namespace of their child routes. For example, in the block below

scope path: "/admin" do
  get "/dashboard", to: "admin_dashboard#show"
end

the route defined by the call to get has the full path /admin/dashboard. We track these contributions via getPathComponent and getControllerComponent.

Import path

import codeql.ruby.frameworks.ActionDispatch

Direct supertypes

Known direct subtypes

    Predicates

    getAPrimaryQlClass

    Gets the name of a primary CodeQL class to which this route block belongs.

    getAStmt

    Gets a Stmt within this route block.

    getControllerComponent

    Gets the component of the controller namespace defined by this block, if it exists.

    getLocation

    Gets the location of this route block.

    getParent

    Gets the parent of this route block, if one exists.

    getParent

    Gets the nth parent of this route block. The zeroth parent is this block, the first parent is the direct parent of this block, etc.

    getPathComponent

    Gets the component of the path defined by this block, if it exists.

    toString

    Gets a string representation of this route block.