Class: Merb::Template::Markaby
- Inherits:
-
Object
- Object
- Merb::Template::Markaby
- Defined in:
- lib/merb_markaby/template.rb
Defined Under Namespace
Modules: Mixin
Class Method Summary collapse
-
.compile_template(path, name, mod) ⇒ Object
Parameters path<String>:: A full path to the template name<String>:: The name of the method that will be created mod<Module>:: The module that the compiled method will be placed into.
Class Method Details
.compile_template(path, name, mod) ⇒ Object
Parameters
- path<String>
-
A full path to the template
- name<String>
-
The name of the method that will be created
- mod<Module>
-
The module that the compiled method will be placed into
9 10 11 12 13 14 |
# File 'lib/merb_markaby/template.rb', line 9 def self.compile_template(path, name, mod) path = File.(path) template = ::Markaby::Template.new(File.read(path)) template.def_method(mod, name) name end |