class ActionDispatch::Journey::Formatter::MissingRoute
def initialize(constraints, missing_keys, unmatched_keys, routes, name)
def initialize(constraints, missing_keys, unmatched_keys, routes, name) @constraints = constraints @missing_keys = missing_keys @unmatched_keys = unmatched_keys @routes = routes @name = name end
def message
def message message = +"No route matches #{Hash[constraints.sort_by { |k, v| k.to_s }].inspect}" message << ", missing required keys: #{missing_keys.sort.inspect}" if missing_keys && !missing_keys.empty? message << ", possible unmatched constraints: #{unmatched_keys.sort.inspect}" if unmatched_keys && !unmatched_keys.empty? message end
def params
def params path("unknown") end
def path(method_name)
def path(method_name) raise ActionController::UrlGenerationError.new(message, routes, name, method_name) end