NAME

Sys::Info::Driver::Windows::OS - Windows backend for Sys::Info::OS

SYNOPSIS

This is a private sub-class.

DESCRIPTION

This document only discusses the driver specific parts.

METHODS

version

Version method returns the Windows version in %d.%d.%d format. Possible version values and corresponding names are:

Version   Windows
-------   -------
0.0.0     Win32s
1.4.0     Windows 95
1.4.10    Windows 98
1.4.90    Windows Me
2.3.51    Windows NT 3.51
2.4.0     Windows NT 4
2.5.0     Windows 2000
2.5.1     Windows XP
2.5.2     Windows Server 2003
2.6.0     Windows Vista
2.6.0     Windows Server 2008*

It is also possible to get the short version (5.1 instead of 2.5.1 for XP) if you pass the short parameter with a true value:

my $v = $os->version( short => 1 );

* Unfortunately Windows Server 2008 has the same version number as Vista. One needs to check the name method to differentiate:

if ( $os->version eq '2.6.0' ) {
    if ( $os->name eq 'Windows Server 2008' ) {
        print "We have the server version, all right";
    }
    else {
        print "Vista";
    }
}
else {
    print "Old Technology";
}

SEE ALSO

Win32, Sys::Info, Sys::Info::OS, http://www.codeguru.com/cpp/w-p/system/systeminformation/article.php/c8973, http://msdn.microsoft.com/en-us/library/cc216469.aspx, http://msdn.microsoft.com/en-us/library/ms724358(VS.85).aspx .

AUTHOR

Burak Gürsoy, <burak@cpan.org>

COPYRIGHT

Copyright 2006-2008 Burak Gürsoy. All rights reserved.

LICENSE

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.

1 POD Error

The following errors were encountered while parsing the POD:

Around line 372:

Non-ASCII character seen before =encoding in 'Gürsoy,'. Assuming UTF-8