Struct.new(:backtrace)
Object representing a method call site. It corresponds to a part of the callstack starting from the context that called the method.
Name of the class holding the method where the call originated. Might return nil if it could not be determined.
# File lib/rcov/call_site_analyzer.rb, line 85 def calling_class(level = 0) stack_frame = backtrace[level] stack_frame ? stack_frame[0] : nil end
Name of the method where the call originated. Returns nil if the call originated in toplevel. Might return nil if it could not be determined.
# File lib/rcov/call_site_analyzer.rb, line 78 def calling_method(level = 0) stack_frame = backtrace[level] stack_frame ? stack_frame[1] : nil end
whose information is included in the CallSite object.
# File lib/rcov/call_site_analyzer.rb, line 57 def depth backtrace.size end
Generated with the Darkfish Rdoc Generator 2.