Class: AdLint::FileWiseMessageSuppressor

Inherits:
MessageSuppressor show all
Defined in:
lib/adlint/supp.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from MessageSuppressor

#suppress?

Constructor Details

#initialize(target_msg_ids, annot_loc) ⇒ FileWiseMessageSuppressor

Returns a new instance of FileWiseMessageSuppressor.



94
95
96
97
# File 'lib/adlint/supp.rb', line 94

def initialize(target_msg_ids, annot_loc)
  super(target_msg_ids)
  @key = [annot_loc.fpath]
end

Instance Attribute Details

#keyObject (readonly)

Returns the value of attribute key.



99
100
101
# File 'lib/adlint/supp.rb', line 99

def key
  @key
end

Class Method Details

.key_of(loc) ⇒ Object



90
91
92
# File 'lib/adlint/supp.rb', line 90

def self.key_of(loc)
  [loc.fpath]
end

Instance Method Details

#file_wise?Boolean

Returns:

  • (Boolean)


101
102
103
# File 'lib/adlint/supp.rb', line 101

def file_wise?
  true
end

#line_wise?Boolean

Returns:

  • (Boolean)


105
106
107
# File 'lib/adlint/supp.rb', line 105

def line_wise?
  false
end