class Haml::Engine

def initialize(template, options = {})

Raises:
  • (Haml::Error) - if there's a Haml syntax error in the template

Parameters:
  • options ({Symbol => Object}) -- An options hash;
  • template (String) -- The Haml template
def initialize(template, options = {})
  @options = Options.new(options)
  @template = check_haml_encoding(template) do |msg, line|
    raise Haml::Error.new(msg, line)
  end
  @temple_engine = TempleEngine.new(options)
  @temple_engine.compile(@template)
end