Module: Delfos::MethodLogging
- Extended by:
- MethodLogging
- Included in:
- MethodLogging
- Defined in:
- lib/delfos/method_logging.rb,
lib/delfos/method_logging/code_location.rb,
lib/delfos/method_logging/call_site_parsing.rb,
lib/delfos/method_logging/method_parameters.rb
Defined Under Namespace
Classes: CallSiteParsing, CodeLocation, MethodParameters
Instance Method Summary
collapse
Instance Method Details
#exclude?(method) ⇒ Boolean
21
22
23
24
25
26
|
# File 'lib/delfos/method_logging.rb', line 21
def exclude?(method)
file, = method.source_location
return true unless file
exclude_file?(File.expand_path(file))
end
|
#exclude_file?(file) ⇒ Boolean
#include_file?(file) ⇒ Boolean
28
29
30
|
# File 'lib/delfos/method_logging.rb', line 28
def include_file?(file)
!exclude_file?(file)
end
|
#log(call_site, called_object, called_method, class_method, parameters) ⇒ Object
15
16
17
18
19
|
# File 'lib/delfos/method_logging.rb', line 15
def log(call_site, called_object, called_method, class_method, parameters)
called_code = CodeLocation.from_called(called_object, called_method, class_method)
Delfos.call_site_logger.log(parameters, call_site, called_code)
end
|
#reset! ⇒ Object
38
39
40
|
# File 'lib/delfos/method_logging.rb', line 38
def reset!
@cache = nil
end
|
#save_call_stack(call_sites, execution_number) ⇒ Object
11
12
13
|
# File 'lib/delfos/method_logging.rb', line 11
def save_call_stack(call_sites, execution_number)
Delfos.call_site_logger.save_call_stack(call_sites, execution_number)
end
|