File: loggable.rbs

package info (click to toggle)
ruby-httpx 1.7.2-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,816 kB
  • sloc: ruby: 12,209; makefile: 4
file content (21 lines) | stat: -rw-r--r-- 564 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
module HTTPX
  interface _IOLogger
    def <<: (string?) -> void
  end

  module Loggable
    USE_DEBUG_LOG: bool

    COLORS: Hash[Symbol, Integer]

    def log: (?level: Integer?, ?color: Symbol?, ?debug_level: Integer, ?debug: _IOLogger?) { () -> String } -> void

    def log_exception: (Exception error, ?level: Integer, ?color: Symbol, ?debug_level: Integer, ?debug: _IOLogger?) -> void

    def log_redact_headers: (_ToS text) -> String

    def log_redact_body: (_ToS text) -> String

    def log_redact: (_ToS text, bool should_redact) -> String
  end
end