class Roadie::UrlGenerator
def generate_url(path, base = "/")
-
(String)
- an absolute URL
Parameters:
-
base
(String
) -- The base which the relative path comes from
Other tags:
- Example: Conversions with a base -
Example: Normal conversions -
def generate_url(path, base = "/") return root_uri.to_s if path.nil? or path.empty? return path if path_is_anchor?(path) return add_scheme(path) if path_is_schemeless?(path) return path if Utils.path_is_absolute?(path) combine_segments(root_uri, base, path).to_s end