Sha256: f7779e05d5587e651d426345aecec47f1bc45cda795b44ae6a0ec59f7f095903
Contents?: true
Size: 805 Bytes
Versions: 41
Compression:
Stored size: 805 Bytes
Contents
module Celerity class JavascriptDebugger include Java::net.sourceforge.htmlunit.corejs.javascript.debug.Debugger def handleCompilationDone(ctx, script, source) p debug_info_for(script).merge(:source_code => source) end def getFrame(ctx, script) p debug_info_for(script) end private def string_for_context(ctx) ctx.toString end def string_for_script(script) script.toString end def debug_info_for(script) { :source => "#{script.getSourceName}:#{script.getLineNumbers.to_a.join(",")}", :function_name => script.getFunctionName, :params => (0...script.getParamAndVarCount).map { |idx| script.getParamOrVarName(idx) }, :function? => script.isFunction, } end end end
Version data entries
41 entries across 41 versions & 6 rubygems