# typed: true

# DO NOT EDIT MANUALLY
# This is an autogenerated file for types exported from the `stackprof` gem.
# Please instead update this file by running `bin/tapioca gem stackprof`.

module StackProf
  class << self
    def results(*_arg0); end
    def run(*_arg0); end
    def running?; end
    def sample; end
    def start(*_arg0); end
    def stop; end
    def use_postponed_job!; end
  end
end

class StackProf::Middleware
  def initialize(app, options = T.unsafe(nil)); end

  def call(env); end

  class << self
    def enabled; end
    def enabled=(_arg0); end
    def enabled?(env); end
    def interval; end
    def interval=(_arg0); end
    def metadata; end
    def metadata=(_arg0); end
    def mode; end
    def mode=(_arg0); end
    def path; end
    def path=(_arg0); end
    def raw; end
    def raw=(_arg0); end
    def save; end
  end
end

class StackProf::Report
  def initialize(data); end

  def +(other); end
  def add_lines(a, b); end
  def convert_to_d3_flame_graph_format(name, stacks, depth); end
  def data; end
  def files; end
  def flamegraph_row(f, x, y, weight, addr); end
  def flamegraph_stacks(raw); end
  def frames(sort_by_total = T.unsafe(nil)); end
  def max_samples; end
  def modeline; end
  def normalized_frames; end
  def overall_samples; end
  def print_alphabetical_flamegraph(f = T.unsafe(nil), skip_common = T.unsafe(nil)); end
  def print_callgrind(f = T.unsafe(nil)); end
  def print_d3_flamegraph(f = T.unsafe(nil), skip_common = T.unsafe(nil)); end
  def print_debug; end
  def print_dump(f = T.unsafe(nil)); end
  def print_file(filter, f = T.unsafe(nil)); end
  def print_files(sort_by_total = T.unsafe(nil), limit = T.unsafe(nil), f = T.unsafe(nil)); end
  def print_flamegraph(f, skip_common, alphabetical = T.unsafe(nil)); end
  def print_graphviz(options = T.unsafe(nil), f = T.unsafe(nil)); end
  def print_json(f = T.unsafe(nil)); end
  def print_method(name, f = T.unsafe(nil)); end
  def print_stackcollapse; end
  def print_text(sort_by_total = T.unsafe(nil), limit = T.unsafe(nil), select_files = T.unsafe(nil), reject_files = T.unsafe(nil), select_names = T.unsafe(nil), reject_names = T.unsafe(nil), f = T.unsafe(nil)); end
  def print_timeline_flamegraph(f = T.unsafe(nil), skip_common = T.unsafe(nil)); end
  def version; end
  def walk_method(name); end

  private

  def callers_for(addr); end
  def root_frames; end
  def source_display(f, file, lines, range = T.unsafe(nil)); end

  class << self
    def from_file(file); end
    def from_json(json); end
    def parse_json(json); end
  end
end

StackProf::Report::MARSHAL_SIGNATURE = T.let(T.unsafe(nil), String)
StackProf::VERSION = T.let(T.unsafe(nil), String)
