annotate _test/wmi.pl @ 127:0dce0470a3d8

In the IMPL::Web::ControllerUnit added the ability to notify a form about a wrong data from a transaction added a relativeUrl function for a usage from a templates IMPL::Web::TT::Form now fully functional
author wizard
date Fri, 11 Jun 2010 20:21:07 +0400
parents 0f3e369553bd
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
49
16ada169ca75 migrating to the Eclipse IDE
wizard@linux-odin.local
parents: 22
diff changeset
1 #!/usr/bin/perl -w
16ada169ca75 migrating to the Eclipse IDE
wizard@linux-odin.local
parents: 22
diff changeset
2 use strict;
16ada169ca75 migrating to the Eclipse IDE
wizard@linux-odin.local
parents: 22
diff changeset
3
59
0f3e369553bd Rewritten property implementation (probably become slower but more flexible)
wizard
parents: 49
diff changeset
4
0f3e369553bd Rewritten property implementation (probably become slower but more flexible)
wizard
parents: 49
diff changeset
5 eval "use Win32::OLE; 1;" if $^ =~ /win/;
49
16ada169ca75 migrating to the Eclipse IDE
wizard@linux-odin.local
parents: 22
diff changeset
6
16ada169ca75 migrating to the Eclipse IDE
wizard@linux-odin.local
parents: 22
diff changeset
7 my $wmi = Win32::OLE->GetObject("winmgmts:{impersonationLevel=impersonate}!\\\\.\\root\\cimv2");
16ada169ca75 migrating to the Eclipse IDE
wizard@linux-odin.local
parents: 22
diff changeset
8
16ada169ca75 migrating to the Eclipse IDE
wizard@linux-odin.local
parents: 22
diff changeset
9 my $colServices = $wmi->ExecQuery("select * from Win32_NetworkAdapterSetting");
16ada169ca75 migrating to the Eclipse IDE
wizard@linux-odin.local
parents: 22
diff changeset
10
16ada169ca75 migrating to the Eclipse IDE
wizard@linux-odin.local
parents: 22
diff changeset
11 print $_->Element,"\t",$_->Setting,"\n" foreach in $colServices;
16ada169ca75 migrating to the Eclipse IDE
wizard@linux-odin.local
parents: 22
diff changeset
12
16ada169ca75 migrating to the Eclipse IDE
wizard@linux-odin.local
parents: 22
diff changeset
13