Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package org.kohsuke.stapler.jelly.jruby.haml;
 

Author(s):
Hiroshi Nakamura
public class HamlLanguage extends RubyTemplateLanguage {
    @Override
    protected String getScriptExtension() {
        return ".haml";
    }
    @Override
    protected Class<HamlClassTearOffgetTearOffClass() {
        return HamlClassTearOff.class;
    }
    @Override
        jruby.put("gem_path"getClass().getResource("/gem").getPath());
        return new RubyTemplateContainer(
            (RubyClass)jruby.runScriptlet("ENV['GEM_PATH'] = gem_path\n" +
                "require 'rubygems'\n" +
                "require 'org/kohsuke/stapler/jelly/jruby/JRubyJellyScriptImpl'\n"+
                "require 'org/kohsuke/stapler/jelly/jruby/haml/JRubyJellyHamlScript'\n"+
                "JRubyJellyScriptImpl::JRubyJellyHamlScript"
            ),
            thisjruby);
    }
New to GrepCode? Check out our FAQ X