Class: Rake::PseudoStatus
- Inherits:
-
Object
- Object
- Rake::PseudoStatus
- Defined in:
- lib/rake/pseudo_status.rb
Overview
Exit status class for times the system just gives us a nil.
Instance Attribute Summary collapse
-
#exitstatus ⇒ Object
readonly
Returns the value of attribute exitstatus.
Instance Method Summary collapse
- #>>(n) ⇒ Object
- #exited? ⇒ Boolean
-
#initialize(code = 0) ⇒ PseudoStatus
constructor
A new instance of PseudoStatus.
- #stopped? ⇒ Boolean
- #to_i ⇒ Object
Constructor Details
#initialize(code = 0) ⇒ PseudoStatus
Returns a new instance of PseudoStatus.
7 8 9 |
# File 'lib/rake/pseudo_status.rb', line 7 def initialize(code=0) @exitstatus = code end |
Instance Attribute Details
#exitstatus ⇒ Object (readonly)
Returns the value of attribute exitstatus
6 7 8 |
# File 'lib/rake/pseudo_status.rb', line 6 def exitstatus @exitstatus end |
Instance Method Details
#>>(n) ⇒ Object
13 14 15 |
# File 'lib/rake/pseudo_status.rb', line 13 def >>(n) to_i >> n end |
#exited? ⇒ Boolean
19 20 21 |
# File 'lib/rake/pseudo_status.rb', line 19 def exited? true end |
#stopped? ⇒ Boolean
16 17 18 |
# File 'lib/rake/pseudo_status.rb', line 16 def stopped? false end |
#to_i ⇒ Object
10 11 12 |
# File 'lib/rake/pseudo_status.rb', line 10 def to_i @exitstatus << 8 end |