Module: Utils::Reporting::Console
- Included in:
- Analyzers::EcbStringAppender, Analyzers::PaddingOracle::Analyzer, Analyzers::Utils::KeyCandidateMap, Analyzers::VigenereXor, Analyzers::VigenereXor::EightBitPatternFinder
- Defined in:
- lib/crypto-toolbox/utils/reporting/console.rb
Instance Method Summary collapse
-
#jot(message, debug: false, raw: false) ⇒ Object
Print to stdout with support of debug conditions This is especially helpfull if the analysis fails or is too slow.
- #print_delimiter_line ⇒ Object
- #print_nice(msg) ⇒ Object
- #print_raw(msg) ⇒ Object
Instance Method Details
#jot(message, debug: false, raw: false) ⇒ Object
Print to stdout with support of debug conditions This is especially helpfull if the analysis fails or is too slow
6 7 8 9 10 |
# File 'lib/crypto-toolbox/utils/reporting/console.rb', line 6 def jot(, debug: false,raw: false) if debug == false || ENV["DEBUG_ANALYSIS"] raw ? print_raw() : print_nice() end end |
#print_delimiter_line ⇒ Object
11 12 13 |
# File 'lib/crypto-toolbox/utils/reporting/console.rb', line 11 def print_delimiter_line puts "=====================================================================" end |
#print_nice(msg) ⇒ Object
18 19 20 |
# File 'lib/crypto-toolbox/utils/reporting/console.rb', line 18 def print_nice(msg) puts msg end |
#print_raw(msg) ⇒ Object
15 16 17 |
# File 'lib/crypto-toolbox/utils/reporting/console.rb', line 15 def print_raw(msg) print msg end |