Class: CpeNameCommandResult
Instance Attribute Summary
#check, #message, #severity, #type
Instance Method Summary
collapse
#visible?
Constructor Details
#initialize(check, severity, message, cpe_name) ⇒ CpeNameCommandResult
Returns a new instance of CpeNameCommandResult.
6
7
8
9
|
# File 'lib/audit/lib/parser/command/cpe_name_command.rb', line 6
def initialize(check, severity, message, cpe_name)
super(check, severity, message || "found program", ResultType::CPE_NAME)
@cpe_name = cpe_name
end
|
Instance Method Details
#get_cpe_name ⇒ Object
11
12
13
|
# File 'lib/audit/lib/parser/command/cpe_name_command.rb', line 11
def get_cpe_name()
return @cpe_name
end
|
#to_hash ⇒ Object
19
20
21
|
# File 'lib/audit/lib/parser/command/cpe_name_command.rb', line 19
def to_hash()
return super.to_hash().merge({:cpe_name => @cpe_name})
end
|
#to_string ⇒ Object
15
16
17
|
# File 'lib/audit/lib/parser/command/cpe_name_command.rb', line 15
def to_string()
return "#{@message}: #{@cpe_name}"
end
|