Name
SPVM::Sys::Time::Timeval - struct timeval in the C language
Description
The Sys::Time::Timeval class in SPVM represents struct timeval in the C language.
Usage
use Sys::Time::Timeval;
my $tv = Sys::Time::Timeval->new;
my $tv = Sys::Time::Timeval->new(5, 100_000);
my $tv_sec = $tv->tv_sec;
$tv->set_tv_sec(12);
my $tv_usec = $tv->tv_usec;
$tv->set_tv_usec(34);
Class Methods
new
static method new : Sys::Time::Timeval ($tv_sec : long = 0, $tv_usec : long = 0);
Creates a new Sys::Time::Timeval
object.
Instance Methods
tv_sec
method tv_sec : long ();
Returns tv_sec
.
set_tv_sec
method set_tv_sec : void ($tv_sec : long);
Sets tv_sec
.
tv_usec
method tv_usec : long ();
Returns tv_usec
.
set_tv_usec
method set_tv_usec : void ($tv_usec : long);
Sets tv_usec
.
Copyright & License
Copyright (c) 2023 Yuki Kimoto
MIT License