Sponsoring The Perl Toolchain Summit 2025: Help make this important event another success Learn more

#
# (c) Jan Gehring <jan.gehring@gmail.com>
#
use v5.12.5;
our $VERSION = '1.16.0'; # VERSION
sub new {
my $that = shift;
my $proto = ref($that) || $that;
my $self = {@_};
bless( $self, $proto );
$self->_read_proc();
return $self;
}
sub _read_proc {
my ($self) = @_;
my $p_cpu = Rex::Inventory::Proc::Cpuinfo->new;
$self->{__proc__} = { cpus => $p_cpu->get, };
}
sub get_cpus {
my ($self) = @_;
return $self->{__proc__}->{cpus};
}
1;