Class: ProgramNameCommand
Constant Summary
collapse
- COMMAND =
"PROGRAM_NAME"
Instance Attribute Summary
#check, #message, #severity
Instance Method Summary
collapse
#process
Constructor Details
#initialize(check, severity, args) ⇒ ProgramNameCommand
31
32
33
34
35
36
37
|
# File 'lib/audit/lib/parser/command/program_name_command.rb', line 31
def initialize(check, severity, args)
@name = args[0].strip if args.length >= 1 or raise ParseException "#{COMMAND} did not supply the program name argument: '#{text}'"
@version = args[1].strip if args.length >= 2
message = (args.length >= 3 ? args[2 .. -1].join : nil)
super(check, severity, message)
end
|
Instance Method Details
#result ⇒ Object
39
40
41
|
# File 'lib/audit/lib/parser/command/program_name_command.rb', line 39
def result()
return ProgramNameCommandResult.new(@check, @severity, @message, @name, @version)
end
|