Sha256: c25eb89deada4bec6e7e43dc0a4726ea3f214e90b65ee1d63a2166fa45d78574
Contents?: true
Size: 717 Bytes
Versions: 1
Compression:
Stored size: 717 Bytes
Contents
module CPU module Shared # Returns the number of processors in this computer def num_processors if defined?(@num_processors) @num_processors else CPU.num_processors end end # Set the number of processors (this causes them to becomed fixed in the # object the CPU::Shared module was mixed into). attr_writer :num_processors # Returns the number of cores in this computer def num_cores if defined?(@num_cores) @num_cores else CPU.num_cores end end # Set the number of cores (this causes them to becomed fixed in the object # the CPU::Shared module was mixed into). attr_writer :num_cores end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
cpu-0.0.6 | lib/cpu/shared.rb |