Class: StackTrace::Viz::HTML

Inherits:
Object
  • Object
show all
Defined in:
lib/stack_trace/viz/html.rb

Constant Summary collapse

LAYOUT_FILE =
"../../public/main.html.erb"

Instance Method Summary collapse

Constructor Details

#initialize(trace, **extra) ⇒ HTML

Returns a new instance of HTML.



12
13
14
15
# File 'lib/stack_trace/viz/html.rb', line 12

def initialize(trace, **extra)
  @trace = trace
  @extra = extra
end

Instance Method Details

#save(file_path) ⇒ Object



17
18
19
20
21
# File 'lib/stack_trace/viz/html.rb', line 17

def save(file_path)
  file_path ||= default_file_path

  File.open(file_path, "w") { |f| f.write(content) }
end