Class: Revelio::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/revelio/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfig



8
9
10
11
12
13
14
15
# File 'lib/revelio/config.rb', line 8

def initialize
  @debug_mode = false
  @project_root = nil
  @inject_overlay = true
  @duration_threshold = 200
  @queries_threshold = 20
  @gc_objects_threshold = 100_000
end

Instance Attribute Details

#debug_modeObject

Returns the value of attribute debug_mode.



5
6
7
# File 'lib/revelio/config.rb', line 5

def debug_mode
  @debug_mode
end

#duration_thresholdObject

Returns the value of attribute duration_threshold.



5
6
7
# File 'lib/revelio/config.rb', line 5

def duration_threshold
  @duration_threshold
end

#gc_objects_thresholdObject

Returns the value of attribute gc_objects_threshold.



5
6
7
# File 'lib/revelio/config.rb', line 5

def gc_objects_threshold
  @gc_objects_threshold
end

#inject_overlayObject

Returns the value of attribute inject_overlay.



5
6
7
# File 'lib/revelio/config.rb', line 5

def inject_overlay
  @inject_overlay
end

#project_rootObject

Returns the value of attribute project_root.



5
6
7
# File 'lib/revelio/config.rb', line 5

def project_root
  @project_root
end

#queries_thresholdObject

Returns the value of attribute queries_threshold.



5
6
7
# File 'lib/revelio/config.rb', line 5

def queries_threshold
  @queries_threshold
end

Instance Method Details

#thresholdsObject



17
18
19
20
21
22
23
# File 'lib/revelio/config.rb', line 17

def thresholds
  {
    duration: @duration_threshold,
    queries: @queries_threshold,
    gc_objects: @gc_objects_threshold
  }
end