Class: OstrichPoll::ExitStatus
- Inherits:
-
Object
- Object
- OstrichPoll::ExitStatus
- Defined in:
- lib/ostrichpoll/exit_status.rb
Instance Attribute Summary collapse
-
#code ⇒ Object
Returns the value of attribute code.
-
#message ⇒ Object
Returns the value of attribute message.
Instance Method Summary collapse
- #exit ⇒ Object
-
#initialize(message, code) ⇒ ExitStatus
constructor
A new instance of ExitStatus.
Constructor Details
#initialize(message, code) ⇒ ExitStatus
Returns a new instance of ExitStatus.
6 7 8 9 |
# File 'lib/ostrichpoll/exit_status.rb', line 6 def initialize(, code) @message = @code = code end |
Instance Attribute Details
#code ⇒ Object
Returns the value of attribute code.
4 5 6 |
# File 'lib/ostrichpoll/exit_status.rb', line 4 def code @code end |
#message ⇒ Object
Returns the value of attribute message.
4 5 6 |
# File 'lib/ostrichpoll/exit_status.rb', line 4 def @message end |
Instance Method Details
#exit ⇒ Object
11 12 13 14 |
# File 'lib/ostrichpoll/exit_status.rb', line 11 def exit puts @message Kernel.exit @code end |