123456789_123456789_123456789_123456789_123456789_

Class: Rake::CpuCounter

Do not use. This class is for internal use only.
Relationships & Source Files
Inherits: Object
Defined in: lib/rake/cpu_counter.rb

Overview

Class Method Summary

Instance Method Summary

Class Method Details

.count

[ GitHub ]

  
# File 'lib/rake/cpu_counter.rb', line 7

def self.count
  new.count_with_default
end

Instance Method Details

#count_with_default(default = 4)

[ GitHub ]

  
# File 'lib/rake/cpu_counter.rb', line 11

def count_with_default(default=4)
  count || default
rescue StandardError
  default
end