Exception: HelpParser::HelpParserException
- Inherits:
-
Exception
- Object
- Exception
- HelpParser::HelpParserException
- Defined in:
- lib/help_parser/exceptions.rb
Direct Known Subclasses
HelpError, HelpException, NoMatch, SoftwareError, UsageError, VersionException
Instance Method Summary collapse
- #_init ⇒ Object
- #exit ⇒ Object
-
#initialize(message) ⇒ HelpParserException
constructor
Must give message.
Constructor Details
#initialize(message) ⇒ HelpParserException
Must give message
8 9 10 11 |
# File 'lib/help_parser/exceptions.rb', line 8 def initialize() _init super end |
Instance Method Details
#_init ⇒ Object
3 4 5 |
# File 'lib/help_parser/exceptions.rb', line 3 def _init @code = 1 end |
#exit ⇒ Object
13 14 15 16 17 18 19 20 |
# File 'lib/help_parser/exceptions.rb', line 13 def exit if @code.positive? REDTTY[] else $stdout.puts end Kernel.exit @code end |