Sha256: 7560b02b8ab0c9d9f8ad1544f8d7024fe6eae366b7ad81fe7ea2b7f6eaf9617d
Contents?: true
Size: 929 Bytes
Versions: 4
Compression:
Stored size: 929 Bytes
Contents
# Copyright (c) 2006 Michael Fellinger m.fellinger@gmail.com # All files in this distribution are subject to the terms of the Ruby license. require 'erubis' module Ramaze module Template # Is responsible for compiling a template using the Erubis templating engine. # Can be found at: http://rubyforge.org/projects/erubis class Erubis < Template ENGINES[self] = %w[ rhtml ] class << self # Entry-point for Action#render def transform action eruby = wrap_compile(action) eruby.result(action.binding) end # Creates an instance of ::Erubis::Eruby, sets the filename # from the template and returns the instance. def compile(action, template) eruby = ::Erubis::Eruby.new(template) eruby.init_evaluator(:filename => (action.template || __FILE__)) eruby end end end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
ramaze-0.1.3 | lib/ramaze/template/erubis.rb |
ramaze-0.1.4 | lib/ramaze/template/erubis.rb |
ramaze-0.2.1 | lib/ramaze/template/erubis.rb |
ramaze-0.2.0 | lib/ramaze/template/erubis.rb |