Perl Date/Time Properties

Any date/time property in Chilkat’s Perl implementation is returned as a SYSTEMTIME object.

Here is sample code that demonstrates getting the ValidTo and ValidFrom property from a digital certificate:

	$sysTime0 = new chilkat::SYSTEMTIME();
	$cert->get_ValidFrom($sysTime0);
	
	$sysTime1 = new chilkat::SYSTEMTIME();
	$cert->get_ValidTo($sysTime1);
	
	print "Valid from " . $sysTime0->{wMonth} . "/" . 
		$sysTime0->{wDay} . "/" . $sysTime0->{wYear} . 
		" to " . $sysTime1->{wMonth} . "/" . $sysTime1->{wDay} . 
		 "/" . $sysTime1->{wYear};

The members of the SYSTEMTIME object are as follows:

// In C++ syntax:
struct SYSTEMTIME {
    unsigned short wYear;
    unsigned short  wMonth;
    unsigned short  wDayOfWeek;
    unsigned short  wDay;
    unsigned short  wHour;
    unsigned short  wMinute;
    unsigned short  wSecond;
    unsigned short  wMilliseconds;
};
Tags :