Method: Webgen::Node#resolve
- Defined in:
- lib/webgen/node.rb
#resolve(path, lang = @lang, msg_on_failure = false) ⇒ Object
Return the node representing the given path
in the given language.
The path can be absolute (i.e. starting with a slash) or relative to the current node. Relative paths are made absolute by using the #alcn of the current node.
If the lang
parameter is not used, it defaults to the language of the current node.
See Tree#resolve_node for detailed information on how the correct node for the path is found and for the msg_on_failure
parameter.
163 164 165 |
# File 'lib/webgen/node.rb', line 163 def resolve(path, lang = @lang, msg_on_failure = false) @tree.resolve_node(Webgen::Path.append(@alcn, path), lang, msg_on_failure) end |